> ## Documentation Index
> Fetch the complete documentation index at: https://relevanceai.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Microsoft Teams

> Microsoft Teams is a collaboration platform that combines workplace chat, video meetings, file storage, and application integration.

With Relevance AI's Microsoft Teams integration, you can connect your Teams workspace to your AI agents, enabling them to monitor channels, respond to messages, and automate communication workflows directly within Teams.

Relevance AI uses a unified Microsoft authentication that works across **Teams**, **Outlook**, **SharePoint**, and **OneDrive** — connecting one account gives you access to all services. See the [Outlook integration](/integrations/popular-integrations/outlook) and [SharePoint knowledge source](/build/knowledge/integrated-knowledge-sources/sharepoint) pages for details on those services.

## Prerequisites

Before setting up the Microsoft Teams integration, ensure you have:

<CardGroup cols={2}>
  <Card title="Relevance AI account" icon="user">
    An active project in Relevance AI
  </Card>

  <Card title="Microsoft Teams access" icon="microsoft">
    Desktop or web app within your organization
  </Card>

  <Card title="Sufficient permissions" icon="lock">
    Enterprise organizations may require admin consent from a Global Administrator or Teams Administrator (see [Admin consent & permissions](#admin-consent-permissions))
  </Card>

  <Card title="A Teams channel or chat" icon="hashtag">
    At least one channel or chat where you want your agent to operate
  </Card>
</CardGroup>

## Setup overview

Setting up Microsoft Teams requires two separate steps. Both are required — completing only one is not enough.

<CardGroup cols={2}>
  <Card title="1. Connect your Microsoft account" icon="plug">
    Authenticate via OAuth in Relevance AI to grant access to Microsoft services.
  </Card>

  <Card title="2. Install the Relevance AI app in Teams" icon="microsoft">
    Add the app from the Teams app store to the channels and chats where your agent should operate.
  </Card>
</CardGroup>

## Step 1 - Connect the integration

<div style={{ width: '100%', position: 'relative', paddingTop: '56.25%' }}>
  <iframe src="https://app.supademo.com/embed/cmmech3sm2nyinr99n7ztmcpx?embed_v=2" frameBorder="0" title="Connect Microsoft Teams integration" allow="clipboard-write; fullscreen" webkitAllowFullscreen="true" mozAllowFullscreen="true" allowFullscreen style={{ position: 'absolute', top: 0, left: 0, width: '100%', height: '100%', border: '3px solid #5E43CE', borderRadius: '10px' }} />
</div>

<Steps>
  <Step title="Open the Integrations page">
    In the Relevance AI dashboard, click **Integrations & API Keys** in the sidebar.
  </Step>

  <Step title="Find the Microsoft integration">
    Locate **Microsoft (Teams, Outlook, SharePoint, OneDrive)** in the list of available integrations.
  </Step>

  <Step title="Add the integration">
    Click **Add Integration**. A pop-up window will open for Microsoft sign-in.

    <Tip>If a pop-up window doesn't appear, check your browser's pop-up blocker settings and allow pop-ups from Relevance AI.</Tip>
  </Step>

  <Step title="Sign in to your Microsoft account">
    Enter your Microsoft credentials in the pop-up window and sign in.

    <Warning>The Microsoft account you sign in with determines which Teams, channels, and chats are visible to the integration. Use the account that has access to the channels your agent needs to operate in.</Warning>
  </Step>

  <Step title="Grant permissions">
    Review the requested permissions and click **Accept**. These permissions allow Relevance AI to read and send messages, access channel and team information, and maintain a persistent connection.

    <Warning>If you see a "Need admin approval" message, your organization's Azure AD / Entra ID tenant restricts third-party app consent. See [Admin consent & permissions](#admin-consent-permissions) for next steps.</Warning>

    For a full list of requested scopes, see the [Permissions reference](#permissions-reference).
  </Step>

  <Step title="Confirm the connection">
    Once complete, you'll see a green **Connected** status indicator next to the Microsoft integration in Relevance AI.
  </Step>
</Steps>

## Step 2 - Install the Relevance AI app in Microsoft Teams

After connecting your Microsoft account, you need to install the Relevance AI app in Teams so your agents can interact with channels and chats.

<Warning>The Relevance AI app must be added to every channel and group chat where you want your agent to respond. Triggers and tool steps will not work in channels or chats where the app has not been added.</Warning>

<Steps>
  <Step title="Open the Teams app store">
    In Microsoft Teams, click on **Apps** in the left sidebar.
  </Step>

  <Step title="Search for the Relevance AI app">
    Type **Relevance AI** in the search bar and locate the app in the results.

    <Note>If you don't see the Relevance AI app, your organization may restrict third-party app installations. See [Admin consent & permissions](#admin-consent-permissions) for how to request approval.</Note>
  </Step>

  <Step title="Install the app">
    Click **Add** or **Install** to add the Relevance AI app to your Teams workspace.
  </Step>

  <Step title="Add the app to specific channels and chats">
    After installing, add the app to each channel or group chat where you want your agent to operate.

    <Tabs>
      <Tab title="Channels">
        1. Navigate to the channel where you want your agent to work
        2. Click the **+** icon at the top of the channel to add a tab or app
        3. Search for **Relevance AI** in the app picker
        4. Select the app and click **Save**
      </Tab>

      <Tab title="Group chats">
        1. Open the group chat where you want your agent to work
        2. Click the **+** icon or **Add apps** button
        3. Search for and select **Relevance AI**
        4. Add the app to the chat
      </Tab>
    </Tabs>
  </Step>

  <Step title="Verify the app is active">
    Confirm the Relevance AI app appears in the channel's app list and that the channel shows up in the trigger setup dropdown in Relevance AI.
  </Step>
</Steps>

## Triggers

<Frame caption="A two-way conversation between a user and a Relevance AI agent in a Teams channel.">
  <img src="https://mintcdn.com/relevanceai/NCT-xXeYjeouWKPv/images/trigger-agent-from-teams.png?fit=max&auto=format&n=NCT-xXeYjeouWKPv&q=85&s=6058e8537a497d84f329fab8d0e098eb" alt="Trigger conversation in Teams" width="1167" height="714" data-path="images/trigger-agent-from-teams.png" />
</Frame>

Triggers let your agents respond to Teams messages automatically, so your team can get answers, run workflows, and escalate issues without leaving their existing conversations. Instead of switching to a separate tool, users interact with agents right where they already communicate.

The Relevance AI app is available on the Microsoft Teams marketplace. Users can @mention or message the app in channels, group chats, or direct messages to trigger agents and have two-way conversations directly in Teams. The same trigger setup also works for [workforces](/build/workforces/create-a-workforce).

<Warning>Teams triggers activate only on new messages. They do not trigger on new chat creation, group creation, or webhooks.</Warning>

### Setting up a trigger

<Note>Before setting up a trigger, confirm that you have completed both <a href="#step-1-connect-the-integration">Step 1: Connect the integration</a> and <a href="#step-2-install-the-relevance-ai-app-in-microsoft-teams">Step 2: Install the Relevance AI app</a>.</Note>

<div style={{ width: '100%', position: 'relative', paddingTop: '56.25%' }}>
  <iframe src="https://app.supademo.com/embed/cmmec8qme2nvjnr99ijtnqf0k?embed_v=2" frameBorder="0" title="Set up Microsoft Teams trigger" allow="clipboard-write; fullscreen" webkitAllowFullscreen="true" mozAllowFullscreen="true" allowFullscreen style={{ position: 'absolute', top: 0, left: 0, width: '100%', height: '100%', border: '3px solid #5E43CE', borderRadius: '10px' }} />
</div>

<Steps>
  <Step title="Open your agent's settings">
    Navigate to your agent in Relevance AI and go to the **Triggers** section.
  </Step>

  <Step title="Add a Microsoft Teams trigger">
    Click **Add Trigger** and select **Microsoft Teams** from the list.
  </Step>

  <Step title="Select the Team and channel">
    Choose the Microsoft account you connected, then select the **Team** and specific **channel** or **chat** you want to monitor.

    <Note>Only channels where the authenticated user is a member and the Relevance AI app has been added will appear in the dropdown.</Note>
  </Step>

  <Step title="Configure trigger conditions (optional)">
    Set up **keyword matching** to filter which messages activate your agent. Leave the keyword field empty to trigger on all messages, or enter specific keywords separated by commas. The trigger checks whether any of the keywords appear anywhere in the message text (case-insensitive).
  </Step>

  <Step title="Write agent instructions">
    In the **Core Instructions** section, write a prompt that guides how your agent should respond — including its role, tone, and when to respond.
  </Step>
</Steps>

<Tip>Set tool permissions to "approval mode" initially so your agent asks before sending messages. Switch to autopilot once you're confident.</Tip>

### How triggered conversations work

Once a trigger fires, the agent responds directly inside Teams with the following capabilities:

<CardGroup cols={3}>
  <Card title="Threaded conversations" icon="comments">
    Agent replies are threaded in the channel. Conversation threads stay active for 30 minutes.
  </Card>

  <Card title="Adaptive Cards" icon="table-layout">
    Responses are delivered as Microsoft Adaptive Cards — rich, interactive messages inside Teams.
  </Card>

  <Card title="Typing indicator" icon="ellipsis">
    Teams displays a typing indicator while the agent is processing a response.
  </Card>

  <Card title="File and image attachments" icon="paperclip">
    Agents can receive and process inline images, pasted screenshots, and uploaded files (PDFs, documents, images) from Teams conversations.
  </Card>

  <Card title="Proactive messages" icon="paper-plane">
    Agents can send direct messages to users without the user initiating first.
  </Card>

  <Card title="Workforce triggers" icon="users-gear">
    Teams messages can trigger an entire workforce, not just an individual agent.
  </Card>
</CardGroup>

<Note>Messages that contain only attachments with no text will show a "\[N attachments]" indicator to the agent.</Note>

## Tool steps for Microsoft Teams

<div style={{ width: '100%', position: 'relative', paddingTop: '56.25%' }}>
  <iframe src="https://app.supademo.com/embed/cmmbee6og0j1y22c40mj0hzvt?embed_v=2" frameBorder="0" title="Microsoft Teams tool steps" allow="clipboard-write; fullscreen" webkitAllowFullscreen="true" mozAllowFullscreen="true" allowFullscreen style={{ position: 'absolute', top: 0, left: 0, width: '100%', height: '100%', border: '3px solid #5E43CE', borderRadius: '10px' }} />
</div>

The Microsoft Teams integration provides actions your agents can use as tool steps in their workflows.

<CardGroup cols={3}>
  <Card title="Send Channel Message" icon="message">
    Post a message to a specific Teams channel
  </Card>

  <Card title="Send Chat Message" icon="comment">
    Send a direct message in Teams
  </Card>

  <Card title="Create Channel" icon="plus">
    Create a new channel in a Team
  </Card>

  <Card title="List Teams" icon="users">
    Get all teams the authenticated user belongs to
  </Card>

  <Card title="List Channels" icon="list">
    Get all channels in a Team
  </Card>

  <Card title="Retrieve Chat Messages" icon="inbox">
    Fetch messages from a specific chat conversation
  </Card>

  <Card title="Search Messages" icon="magnifying-glass">
    Search for messages across Teams channels and chats
  </Card>

  <Card title="List Shifts" icon="calendar-days">
    Retrieve shift information from Teams
  </Card>

  <Card title="Microsoft API Call" icon="code">
    Make custom calls to Microsoft Graph API
  </Card>
</CardGroup>

<Note>
  Most Microsoft Teams tool steps are currently in beta. Please report any issues to our support team.
</Note>

## Agent alerts

<Frame caption="Configuring agent notification rules in Relevance AI.">
  <img src="https://mintcdn.com/relevanceai/fIvBQzX3CrTIQ7hf/images/team-agent-notifications.png?fit=max&auto=format&n=fIvBQzX3CrTIQ7hf&q=85&s=56e17a5bf5a8abe2dba27649c4fee470" alt="Agent notification configuration" width="2844" height="1844" data-path="images/team-agent-notifications.png" />
</Frame>

You can receive notifications in Microsoft Teams when your agents enter specific statuses or encounter tool errors. This helps you monitor agent activity and respond quickly when issues occur.

<Note>Agent notifications are currently in beta and may not be available for all accounts.</Note>

### Setting up Teams notifications

<Steps>
  <Step title="Open the escalations panel">
    Navigate to your agent and click the **Build** tab, then click **Escalations** in the left sidebar.
  </Step>

  <Step title="Add an agent notification">
    Under "Agent Notifications", click **Add agent notification**.
  </Step>

  <Step title="Configure notification settings">
    Select **Microsoft Teams** as the platform, then choose the notification trigger: **Agent enters status** (select specific task statuses such as "Running", "Completed", or "Failed") or **Tool errors (any tool)** to get notified when any tool encounters an error. Select a Microsoft Teams account and the channel where you want to receive notifications. If no accounts appear, complete the [connection steps](#step-1-connect-the-integration) first.
  </Step>

  <Step title="Publish changes">
    Click **Publish changes** to save your notification configuration.
  </Step>
</Steps>

<Tip>Test the notification by running your agent — you should receive a notification in your selected Teams channel based on your configured triggers.</Tip>

### What you'll receive

When a notification is triggered, you'll receive a message in your Teams channel containing:

<CardGroup cols={2}>
  <Card title="Agent status and context" icon="circle-info">
    Agent name, status, and task details
  </Card>

  <Card title="Direct link" icon="arrow-up-right-from-square">
    Link to view the full task in Relevance AI
  </Card>

  <Card title="Error details" icon="triangle-exclamation">
    For tool errors: which tool failed and why
  </Card>
</CardGroup>

## Admin consent & permissions

Enterprise organizations often require administrator approval before users can connect third-party applications or install apps in Microsoft Teams.

### Understanding admin consent

Microsoft Azure AD (Entra ID) allows tenant administrators to restrict whether users can grant consent to third-party apps on their own. When this restriction is active, individual users will see a "Need admin approval" screen during the OAuth flow instead of the standard consent prompt. This is a tenant-level policy — it is not specific to Relevance AI.

If you see "Need admin approval" or "This app requires admin approval", follow the steps below.

<Tabs>
  <Tab title="OAuth connection approval">
    If you see an admin approval message when connecting your Microsoft account:

    <Steps>
      <Step title="Copy the consent URL">
        Copy the **consent URL** that appears in the Microsoft login window. This URL contains the specific permissions Relevance AI is requesting.
      </Step>

      <Step title="Forward the URL to your administrator">
        Send the URL to your **Microsoft 365 Global Administrator or Application Administrator** with a request to grant consent. Include a brief explanation of what Relevance AI is and how it will be used.
      </Step>

      <Step title="Wait for admin approval">
        Your administrator will open the URL, review the requested permissions, and click **Accept** to grant consent on behalf of the organization.
      </Step>

      <Step title="Retry the connection">
        Return to Relevance AI and **retry the Microsoft integration connection**. The consent prompt should no longer appear.
      </Step>
    </Steps>
  </Tab>

  <Tab title="Teams app installation approval">
    If your organization requires admin approval for app installations:

    <Steps>
      <Step title="Contact your IT administrator">
        Request approval to install the Relevance AI app in Microsoft Teams.
      </Step>

      <Step title="Wait for admin approval">
        Your administrator will go to the [Microsoft Teams Admin Center](https://admin.teams.microsoft.com), navigate to **Teams apps** > **Manage apps**, search for **Relevance AI**, and change the app status to **Allowed**.
      </Step>

      <Step title="Install the app">
        Once approved, follow the steps in [Step 2: Install the Relevance AI app](#step-2-install-the-relevance-ai-app-in-microsoft-teams).
      </Step>
    </Steps>
  </Tab>
</Tabs>

## Permissions reference

The following OAuth scopes are requested when you connect your Microsoft account. These permissions allow Relevance AI to read and send messages, access team and channel metadata, and maintain persistent access.

| Scope                     | Description                                                    |
| ------------------------- | -------------------------------------------------------------- |
| `offline_access`          | Maintains access without requiring frequent re-authentication  |
| `Chat.Create`             | Create new chats                                               |
| `Chat.ReadWrite`          | Read and write to chats the user has access to                 |
| `ChatMessage.Read`        | Read chat messages                                             |
| `ChatMessage.Send`        | Send chat messages                                             |
| `ChannelMessage.Read.All` | Read messages in channels the user has access to               |
| `ChannelMessage.Send`     | Send messages to channels                                      |
| `Channel.ReadBasic.All`   | Read basic channel information (name, description, ID)         |
| `Team.ReadBasic.All`      | Read basic team information (name, description, ID)            |
| `User.Read`               | Read the signed-in user's profile                              |
| `User.Read.All`           | List users in the organization (used for trigger user filters) |

<Note>These permissions may evolve as new features are added to the integration. Any changes will be reflected in the OAuth consent prompt.</Note>

## Troubleshooting

<AccordionGroup>
  <Accordion title="'The application is not authorized' error">
    This error means your Azure AD / Entra ID tenant has not granted consent for Relevance AI. Ask your Microsoft 365 Global Administrator to grant admin consent using the steps in [Admin consent & permissions](#admin-consent-permissions). Once consent is granted, retry the connection from the Integrations page.
  </Accordion>

  <Accordion title="'Consent was denied' error">
    This occurs when you or your administrator explicitly declined the permissions request during the OAuth flow. To resolve this, retry the integration connection from the Integrations page and click **Accept** when prompted. If the consent was denied by an admin policy, your administrator will need to grant consent on your behalf.
  </Accordion>

  <Accordion title="Relevance AI app not visible in the Teams app store">
    If the Relevance AI app does not appear in the Teams app store, your organization likely restricts third-party app installations. Ask your IT administrator to allow the app in the [Microsoft Teams Admin Center](https://admin.teams.microsoft.com) under **Teams apps** > **Manage apps**. See [Admin consent & permissions](#admin-consent-permissions) for detailed steps.
  </Accordion>

  <Accordion title="Teams trigger option not visible in agent settings">
    Some Teams features are controlled by feature flags and may not be enabled for all accounts. If you don't see Microsoft Teams as a trigger option in your agent or workforce settings, [contact our support team](/get-started/support) to check whether the feature needs to be enabled for your account.
  </Accordion>

  <Accordion title="Trigger is configured but the agent isn't responding">
    Verify that the Relevance AI app has been added to the specific channel or chat being monitored (not just installed in Teams), and that the Microsoft account used for the trigger is a member of the channel. Confirm the trigger is enabled and published in your agent's settings. If keyword matching is configured, check that messages contain the expected keywords. Review the agent's task logs in Relevance AI for errors — a `401 Unauthorized` error indicates the OAuth token has expired or been revoked, and you should reconnect the Microsoft integration.
  </Accordion>
</AccordionGroup>

## Frequently asked questions (FAQs)

<AccordionGroup>
  <Accordion title="Who supports the Microsoft Teams integration?">
    The Microsoft Teams integration is built and maintained by Relevance AI. For integration-specific questions, [contact our support team](/get-started/support). For Microsoft Teams platform issues, contact [Microsoft support](https://support.microsoft.com/).
  </Accordion>

  <Accordion title="Why don't I see my Teams channel in the dropdown when setting up a trigger?">
    The most common cause is that the Relevance AI app has not been installed in Teams or added to the specific channel. The Microsoft account you connected must also be a member of that channel. If your organization requires admin consent, the app may not be visible until an administrator approves it. Verify that you've completed both setup steps and added the app to the channel.
  </Accordion>

  <Accordion title="Can I connect multiple Microsoft accounts?">
    Yes, you can connect multiple Microsoft accounts through the Integrations & API Keys page. Each account can be used for different triggers and tool steps.
  </Accordion>

  <Accordion title="Do triggers work for private messages?">
    Yes, Teams triggers can monitor both channel messages and private chats. To monitor direct messages, select the "Direct chats with Relevance AI" option when configuring your trigger instead of a specific channel.
  </Accordion>

  <Accordion title="Can my agent access files shared in Teams?">
    Yes, files shared in Teams channels are stored in SharePoint. You can access them through the Microsoft API Call tool step via the Microsoft Graph API.
  </Accordion>

  <Accordion title="What's the difference between the pre-built tool steps and the API Call tool step?">
    Pre-built tool steps (like "Send Channel Message") are designed for common tasks with simplified interfaces. The Microsoft API Call tool step gives you full access to Microsoft Graph API for advanced operations not covered by pre-built steps.
  </Accordion>

  <Accordion title="Are there rate limits for Microsoft Teams API calls?">
    Yes, Microsoft Graph API enforces rate limits depending on your Microsoft 365 subscription. Microsoft returns a `429 Too Many Requests` status code when limits are exceeded.
  </Accordion>

  <Accordion title="How do I remove the Microsoft Teams integration?">
    Go to the **Integrations & API Keys** page from the sidebar, find **Microsoft (Teams, Outlook, SharePoint, OneDrive)**, click "..." on the account you want to remove, and click "Remove" and confirm. This will disable all triggers and tool steps using this account across Teams, Outlook, SharePoint, and OneDrive. To also remove the app from Microsoft Teams, go to **Apps** in Teams, find Relevance AI, and click **Uninstall**.
  </Accordion>
</AccordionGroup>
