> For the complete documentation index, see [llms.txt](https://kb.theloops.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://kb.theloops.io/agentstudio/integrations/microsoft-teams.md).

# Microsoft Teams

## Overview <a href="#overview" id="overview"></a>

The Microsoft Teams integration connects IFS Loops to your Teams environment so a Digital Worker can access and act on Teams messages. Setup has three parts: installing the IFS TheLoops bot at the organization level in the Microsoft Teams Admin Center, creating a dedicated channel for a Digital Worker's human in the loop review, and configuring the connector in IFS Loops so it can ingest and analyze channel messages. The connector supports two capabilities: Helpdesk and Collaboration, and uses OAuth-based authentication with automatic token persistence to keep the connection active.

### Prerequisites

* Admin access to the Microsoft Teams Admin Center, to install or update the IFS TheLoops bot.
* The latest IFS TheLoops Bot ZIP package, provided by the IFS Loops team.
* A Microsoft Teams/Microsoft 365 account with permission to create teams and channels, and to grant consent during authentication.
* Access to the IFS Loops platform with Admin role privileges.
* A dedicated Teams channel for the Digital Worker's human in the loop review, created before configuring the connector (see *Create the digital worker channel* below).
* Know in advance which capability you'll configure, Helpdesk and/or Collaboration, and which channel (Helpdesk) or Team and channel (Collaboration, if using Sandbox) you'll select during configuration.

### Best Practices

* **Regional app name:** The bot appears in the Teams app directory with a regional suffix: *IFS TheLoops US* or *IFS TheLoops EU*. Confirm which applies to your organization, since it's referenced throughout the setup steps below.

### IFS Loops Microsoft Teams Connector – Microsoft Graph Permissions

The following table lists the Delegated Microsoft Graph API permissions used by the IFS Loops Microsoft Teams Connector for collaboration capability.

<details>

<summary><strong>User.Read</strong></summary>

Allows IFS Loops to read the profile information of the user who authorized the Teams connector. This is used to identify the user who initially authenticated/configured the connector.

</details>

<details>

<summary><strong>User.Read.All</strong></summary>

In a Teams channel, different users can interact with the IFS Loops bot. IFS Loops uses this permission to retrieve the basic profile information of the user interacting with the bot, so that it can identify who is interacting with the bot and associate the interaction with the correct user.

</details>

<details>

<summary><strong>Channel.ReadBasic.All</strong></summary>

Allows IFS Loops to retrieve basic information about Teams channels, such as the channel name, channel ID, and channel type. This information is required when configuring a Teams channel for Human-in-the-Loop (HITL) scenarios. For example, when you want a Digital Worker to send notifications to a specific Teams channel, that channel needs to be configured in IFS Loops. It is also used when configuring a Teams channel from which users can invoke a Digital Worker using bot commands.

</details>

<details>

<summary><strong>Team.ReadBasic.All</strong></summary>

Allows IFS Loops to retrieve basic information about Teams, such as the team name and team ID. This is used to identify the Teams team in which the IFS Loops bot is installed and to determine which Teams team is being used with the connector.

</details>

<details>

<summary><strong>offline_access</strong></summary>

Allows IFS Loops to maintain the user's authorization when the access token expires by obtaining a refresh token. This prevents the user from having to authenticate again frequently and allows the connector to continue operating.

</details>

## Setup instructions

### Remove the existing bot

*If a previous version of the bot is installed, remove it first to avoid conflicts. Skip this section on a first-time install.*

{% stepper %}
{% step %}
Log in to the **Microsoft Teams Admin Center**.
{% endstep %}

{% step %}
Navigate to **Teams apps → Manage apps**.
{% endstep %}

{% step %}
Search for the existing bot: *IFS TheLoops US* (US region) or *IFS TheLoops EU* (EU region).
{% endstep %}

{% step %}
Click the app to open its detail page.
{% endstep %}

{% step %}
Click **Actions**, then select **Delete**.
{% endstep %}

{% step %}
Confirm the deletion if prompted.
{% endstep %}
{% endstepper %}

### Refresh the Manage apps page <a href="#step-2-basic-configuration" id="step-2-basic-configuration"></a>

{% stepper %}
{% step %}
Refresh the **Manage apps** page.
{% endstep %}

{% step %}
Confirm the previous bot version is no longer listed.
{% endstep %}
{% endstepper %}

### Create the digital worker channel

*For a Digital Worker to support human in the loop review, a dedicated Teams channel is required.*

{% stepper %}
{% step %}
Go to **Teams and channels**, then click **See all your teams**.
{% endstep %}

{% step %}
Click **Create team**.&#x20;

* This will be the dedicated team for the Digital Worker.&#x20;
* Use an appropriate team name (for example, *IFS Loops Digital Worker*).&#x20;
* Under **Team type**, choose **Private**.&#x20;
* Under **First channel name**, choose an appropriate channel name (for example, *Customer Order Manager Digital Worker human in the loop*).
* Going forward, ensure that any user who needs to interact with the Digital Worker is added to this team.
  {% endstep %}

{% step %}
Go to the channel, click the three dots in the top right, select **Manage channel**, then click **Edit**.&#x20;

* Set **Layout** to **Threads**.
  {% endstep %}

{% step %}
Add the IFS TheLoops bot to this channel (see *Add the bot to a specific channel* above).
{% endstep %}

{% step %}
If applicable, to invite an external guest to the channel:&#x20;

1. Click **Manage team**
2. Go to the **Members** tab
3. Click **Add member**
4. Enter the guest's email address.
   {% endstep %}
   {% endstepper %}

### Upload the new bot package

{% stepper %}
{% step %}
In **Manage apps,** click **Actions**, then **Upload new app**.
{% endstep %}

{% step %}
Select the Bot ZIP file provided by the IFS Loops team.
{% endstep %}

{% step %}
Wait for the upload to complete.
{% endstep %}

{% step %}
Search for *IFS TheLoops US* or *IFS TheLoops EU* to confirm the new version is visible and available.
{% endstep %}
{% endstepper %}

### Add the bot to a team

*This is typically a one-time, organization-level step to make the bot available in Teams. To add it to a specific channel, such as the digital worker channel created below, use **Add the bot to a specific channel** instead.*

{% stepper %}
{% step %}
Open **Microsoft Teams.**
{% endstep %}

{% step %}
Navigate to **Apps** in the left sidebar.
{% endstep %}

{% step %}
Search for **IFS TheLoops** (select *IFS TheLoops US* or *IFS TheLoops EU* depending on your region).
{% endstep %}

{% step %}
Select the bot from the search results, then click **Add**.
{% endstep %}

{% step %}
When prompted, choose the Team or Channel where the bot should be installed and complete the setup.
{% endstep %}

{% step %}
Log out and back into Teams.
{% endstep %}
{% endstepper %}

### Add the bot to a specific channel

{% stepper %}
{% step %}
Navigate to the channel where you want to add the bot.
{% endstep %}

{% step %}
Click the + (**Add a tab**) icon in the top header.
{% endstep %}

{% step %}
Select **Apps**.
{% endstep %}

{% step %}
Search for **IFS TheLoops**, then select it from the results.
{% endstep %}

{% step %}
Click **Save**.&#x20;
{% endstep %}
{% endstepper %}

{% hint style="info" %}
***Note:** if a team has multiple channels that each need the bot, repeat this step for each channel individually.*
{% endhint %}

### Verify the bot installation

{% stepper %}
{% step %}
Navigate to the Team or Channel where the bot was installed.
{% endstep %}

{% step %}
Confirm the bot is visible and active.
{% endstep %}

{% step %}
Perform a test interaction to confirm the bot is functioning.
{% endstep %}

{% step %}
Verify the **Agent Homepage** tab is visible at the top of the page.
{% endstep %}
{% endstepper %}

### Initiate Integration

{% stepper %}
{% step %}
Log in to the IFS Loops platform using your credentials.
{% endstep %}

{% step %}
Navigate to the **Connectors** section from the sidebar.
{% endstep %}

{% step %}
Click **Add Integration**.
{% endstep %}

{% step %}
Choose **Teams** from the list.
{% endstep %}
{% endstepper %}

### Microsoft Teams integration

{% stepper %}
{% step %}
Go to the **Integration Configuration** page.
{% endstep %}

{% step %}
**User Email** *(Optional)*:

* Enter the email address of the Teams account used for authentication.
* This is optional and is used only for identification.
  {% endstep %}

{% step %}
**Select Capability Configuration**:

* *For Collaboration capability:* select the environment (**Production** or **Sandbox**).
* *If Sandbox is selected:* choose the Team that contains the channel you want to use.
* *For Helpdesk capability:* select the channel from which you want to pull messages.
  {% endstep %}

{% step %}
Click **Update**.
{% endstep %}
{% endstepper %}

### Data ingestion job

{% stepper %}
{% step %}
Navigate to the **Jobs / Data Ingestion** tab.
{% endstep %}

{% step %}
Select Ingress Type as **Full Ingress** for Helpdesk capability.
{% endstep %}

{% step %}
Select **Collaboration Channel Ingress** for Collaboration capability.
{% endstep %}

{% step %}
Click **Start Ingress**.
{% endstep %}

{% step %}
After a few minutes, verify the job status is successful.
{% endstep %}
{% endstepper %}

### Regenerate token

{% stepper %}
{% step %}
Go to the **Microsoft Teams integration** and click **Edit**.
{% endstep %}

{% step %}
Navigate to the **Authentication** tab.
{% endstep %}

{% step %}
A login window will appear.
{% endstep %}

{% step %}
Log in using your credentials and grant permissions.
{% endstep %}

{% step %}
On success, you will see the message: “Integration updated successfully.”
{% endstep %}
{% endstepper %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://kb.theloops.io/agentstudio/integrations/microsoft-teams.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
