> ## Documentation Index
> Fetch the complete documentation index at: https://hc.saas-manager.biz.nuro.jp/llms.txt
> Use this file to discover all available pages before exploring further.

# Microsoft Teams integration

> Connect AI Helpdesk to Microsoft Teams so users can send inquiries from Teams. Supports Standard Bot and Custom Bot connection types.

When you connect AI Helpdesk to Microsoft Teams, users can send inquiries to the AI bot from Teams chats.

## Supported connection types

Two connection types are available for Microsoft Teams.

| Type             | Description                                                                       | Best for                                                                                                   |
| ---------------- | --------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- |
| **Standard Bot** | Install via admin consent (OAuth)                                                 | Quick setup / avoiding Azure app registration management                                                   |
| **Custom Bot**   | Register an app in Azure AD and enter App ID, App Password, and other credentials | Full control over app permissions and branding / organizations where public app installation is restricted |

<Note>
  Both types provide the same chat experience (automatic group chat creation, DM support).
</Note>

## Prerequisites

<Info>
  * **Admin** role in AI Helpdesk is required
  * **Standard Bot**: Microsoft Azure AD tenant admin rights required (to grant admin consent)
  * **Custom Bot**: Permission to register and configure bot apps in Azure Active Directory
</Info>

## Connect via Standard Bot

Install the official Admina Teams app using Microsoft admin consent (Admin Consent). No Azure app registration required.

<Steps>
  <Step title="Open Integration settings">
    Select **Settings** from the left navigation and open the **Integration** tab.
    Click **Add connection** in the **Messaging** section and select **Microsoft Teams — Standard Bot**.
  </Step>

  <Step title="Grant admin consent">
    You are redirected to the Microsoft admin consent page.
    Sign in with your Azure AD admin account and approve the permissions for the Admina AI Helpdesk app.
  </Step>

  <Step title="Select an observer user">
    Select at least one observer user to satisfy the group chat member requirement.
    Choose an appropriate user from the list and click **Connect**.

    <Note>
      The observer user is a technical requirement for group chats. In normal operations, use a dedicated account that does not monitor conversation content.
    </Note>
  </Step>

  <Step title="Confirm connection">
    When authentication succeeds, a Microsoft Teams (Standard Bot) card appears in the **Messaging** section.
  </Step>
</Steps>

## Connect via Custom Bot

Register a bot app in Azure AD and enter the credentials in AI Helpdesk.

### Required information

| Field            | Source                                                                          |
| ---------------- | ------------------------------------------------------------------------------- |
| **App ID**       | **Application (client) ID** on the Azure AD app registration page               |
| **App Password** | Client secret issued in **Certificates & secrets** on the app registration page |
| **Tenant ID**    | **Directory (tenant) ID** on the app registration page                          |
| **Teams App ID** | Catalog ID of the app uploaded to the Teams Admin Center                        |

### Azure setup

#### Create a Bot Service

1. In [Azure Portal](https://portal.azure.com/), go to **Bot Service** and select **+ Create** > **Azure Bot**

2. Enter the Bot handle name and tenant settings, then submit

3. For **Microsoft App ID**, choose to create a new one or use an existing app registration

4. In the Bot's **Configuration**, set the **Messaging endpoint** to:

   ```text theme={null}
   https://assist.i.moneyforward.com/chat/teams
   ```

5. Enable the **Microsoft Teams** channel in the Bot's **Channels**

#### Required API permissions

Add the following permissions to **API Permissions** on the app registration and grant **admin consent**.

| Permission                                  | Type        | Purpose                     |
| ------------------------------------------- | ----------- | --------------------------- |
| `AppCatalog.Read.All`                       | Application | Read app catalog            |
| `Channel.ReadBasic.All`                     | Application | Read channel info           |
| `ChannelMessage.Read.All`                   | Application | Read channel messages       |
| `Chat.Create`                               | Application | Create group chats          |
| `Chat.ReadWrite.All`                        | Application | Read and write chat info    |
| `ChatMessage.Read.All`                      | Application | Read chat messages          |
| `Team.ReadBasic.All`                        | Application | List teams                  |
| `TeamsAppInstallation.ReadWriteForChat.All` | Application | Manage Teams apps in chats  |
| `TeamsAppInstallation.ReadWriteForUser.All` | Application | Manage Teams apps for users |
| `User.Read`                                 | Delegated   | Sign-in and profile access  |
| `User.Read.All`                             | Application | Read all user profiles      |

#### Issue a client secret

In **Certificates & secrets** on the app registration, create a new secret and copy the displayed **Value** (it cannot be retrieved later). This value is the **App Password**.

#### Upload the Teams app and get the catalog ID

Upload the app package (zip) in [Microsoft Teams Admin Center](https://admin.teams.microsoft.com/) under **Teams apps > Manage apps**. Copy the catalog ID shown in the app details page URL.

### Connection steps

<Steps>
  <Step title="Open Integration settings">
    Select **Settings** from the left navigation and open the **Integration** tab.
    Click **Add connection** in the **Messaging** section and select **Microsoft Teams — Custom Bot**.
  </Step>

  <Step title="Enter credentials">
    Enter the **App ID**, **App Password**, **Tenant ID**, and **Teams App ID**, then click **Next**.
    The credentials are validated against Azure AD.
  </Step>

  <Step title="Select an observer user">
    Select at least one observer user to satisfy the group chat member requirement.
    Choose an appropriate user from the list and click **Connect**.

    <Note>
      The observer user is a technical requirement for group chats. In normal operations, use a dedicated account that does not monitor conversation content.
    </Note>
  </Step>

  <Step title="Confirm connection">
    When the connection succeeds, a Microsoft Teams card appears in the **Messaging** section.
  </Step>
</Steps>

## Using the bot

After connecting, Teams users can send inquiries by starting a direct chat with the bot. When a user sends a message, a group chat is automatically created and the session begins.

<Tip>
  For DM notifications to users (such as escalation alerts), the `TeamsAppInstallation.ReadWriteForUser.All` permission must be granted on the Azure AD side (Custom Bot only).
</Tip>

## Disconnect Teams

In the **Messaging** section of **Settings > Integration**, click the trash icon on the card you want to disconnect.

<Warning>
  Disconnecting stops all incoming inquiries from that Teams tenant.
</Warning>

## Troubleshooting

**Admin consent denied (Standard Bot)**

Contact your Azure AD admin to approve admin consent for the Admina AI Helpdesk app.
If approval is not possible, consider using **Custom Bot** instead.

**"Invalid credentials" error (Custom Bot)**

* Verify the App ID, App Password, and Tenant ID are correct
* Check that the client secret has not expired

**Bot does not respond**

* Confirm the app is approved and distributed in the Teams Admin Center
* Verify the bot service messaging endpoint URL is configured correctly

## Related pages

* [Slack integration](/en/ai-helpdesk/integrations/slack)
* [LINE WORKS integration](/en/ai-helpdesk/integrations/line-works)
* [Google Chat integration](/en/ai-helpdesk/integrations/google-chat)
