Skip to main content
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, search conversations, and automate communication workflows directly within your team’s collaboration environment. The integration uses native OAuth-based tool steps that call Microsoft Graph API directly, giving you faster execution, more reliable performance, and tighter security compared to third-party relay approaches.

Connect the integration

Connecting your Microsoft account to Relevance AI is a straightforward process. The Microsoft integration provides unified authentication across Teams, Outlook, SharePoint, and OneDrive.
  1. Go to the “Integrations & API Keys” page in the sidebar of your Relevance AI dashboard.
  2. Click on “Microsoft (Teams, Outlook, SharePoint, OneDrive)” from the available integrations.
  3. Click on the “Add Integration” button.
  4. In the pop-up window, sign into your Microsoft account.
  5. Grant the necessary permissions for Relevance AI to access your Microsoft Teams data.
  6. Once authenticated, your Microsoft account will appear as a connected integration.
You may need admin consent depending on your organization’s Microsoft policies. After connecting, you can use Microsoft Teams as a trigger for your agents to automatically respond to messages, or use Teams tool steps in your custom tools to send messages and manage channels.

Microsoft integration overview

Relevance AI uses a unified Microsoft authentication that works across multiple Microsoft services:
  • Microsoft Teams - Monitor and respond to Teams messages
  • Outlook - Access email and calendar
  • SharePoint - Connect to SharePoint sites and documents
  • OneDrive - Access files stored in OneDrive
This means connecting one Microsoft account gives you access to all these services within Relevance AI.

Set up Microsoft Teams as a trigger

You can configure your agents to automatically respond to Microsoft Teams messages by setting up Teams as a trigger. Your agent will process messages in real-time as they are posted to the monitored channel or chat.
Teams triggers activate only on new messages. They do not trigger on new chat creation, group creation, or webhooks.

How to set up the Microsoft Teams trigger

Other trigger settings

Available tool steps

Check out the available tool steps you can connect and use with your trigger to automate responses.

Configure trigger conditions

Optionally set up keyword matching to filter which messages activate your workflow.

Configure tool permissions

Set tool permissions to “approval mode” initially so your agent asks before sending messages. Switch to autopilot once you’re confident.

Write agent instructions

In the “Core Instructions” section, write a prompt that guides your agent on how to respond to Teams messages.

Tool steps for Microsoft Teams

The Microsoft Teams integration provides 10 native OAuth-based tool steps that call Microsoft Graph API directly. These can be incorporated into your agent’s workflows to automate communication and team management tasks.

Team & channel management

List Teams

Retrieve all Microsoft Teams that the authenticated user is a member of

List Channels

Get all channels within a specific Team

Create Channel

Create a new channel in a Team

List Team Members

Retrieve the members of a specific Team
Returns all Teams that the authenticated user belongs to, including the team name, ID, description, and visibility (public or private).Use cases:
  • Let an agent discover which teams exist before routing a message to the right channel
  • Build a dynamic team selector when automating cross-team notifications
  • Audit team membership across your organization
Key parameters: none required — returns results scoped to the authenticated user’s memberships.Output: An array of team objects, each containing id, displayName, description, and visibility.
Returns all channels within a given Team, including channel name, ID, description, and membership type (standard or private).Use cases:
  • Identify the correct channel ID before sending a message
  • List available channels so an agent can present options to a user
  • Check whether a channel already exists before creating a duplicate
Key parameters: teamId — the ID of the Team whose channels you want to list.Output: An array of channel objects, each containing id, displayName, description, and membershipType.
Creates a new standard or private channel within a specified Team.Use cases:
  • Automatically create project-specific channels when a new project is kicked off
  • Set up dedicated support channels for high-priority customers
  • Provision onboarding channels for new team members
Key parameters: teamId, displayName (channel name), description (optional), membershipType (standard or private).Output: The newly created channel object, including its id and webUrl.
Returns the members of a specific Team, including their display names, email addresses, and roles (owner or member).Use cases:
  • Look up a team member’s user ID before sending them a direct message
  • Check whether a specific person is already a member of a team before adding them
  • Generate membership reports for compliance or auditing
Key parameters: teamId — the ID of the Team whose members you want to list.Output: An array of member objects, each containing id, displayName, email, and roles.

Messaging & communication

Send Channel Message

Post a message to a specific Teams channel

Send Chat Message

Send a direct message in a Teams chat

Retrieve Chat Messages

Fetch messages from a specific Teams chat or conversation

Search Messages

Search across Teams messages using keywords or filters
Posts a message to a channel within a specified Team. Supports plain text and basic HTML formatting.Use cases:
  • Send automated status updates to a project channel
  • Post alerts when a monitored event occurs (e.g., a failed deployment or a new support ticket)
  • Notify a team channel when a report is ready
Key parameters: teamId, channelId, content (message body), contentType (text or html).Output: The created message object, including its id and createdDateTime.
Sends a message to an existing one-on-one or group chat thread.Use cases:
  • Send a personalized follow-up message directly to a user
  • Notify a small group chat about a time-sensitive update
  • Reply to a user who contacted your agent via direct message
Key parameters: chatId, content (message body), contentType (text or html).Output: The created message object, including its id and createdDateTime.
Fetches messages from a specific chat thread, returning them in chronological order. Useful for giving your agent context about an ongoing conversation before it responds.Use cases:
  • Read the history of a support chat before drafting a reply
  • Summarize recent conversation context for a handoff between agents
  • Extract action items from a group chat discussion
Key parameters: chatId, top (number of messages to return), skip (pagination offset).Output: An array of message objects, each containing id, from, body, createdDateTime, and lastModifiedDateTime.
Searches across Teams messages using a keyword query, returning matching messages from channels and chats the authenticated user has access to.Use cases:
  • Find all messages mentioning a specific project or customer name
  • Locate a past decision or approval that was recorded in Teams
  • Audit messages containing sensitive terms for compliance purposes
Key parameters: query (search keywords or phrases), top (maximum results to return).Output: An array of matching message objects with id, from, body, channelIdentity or chatInfo, and createdDateTime.

Team operations

List Team Shifts

Retrieve shift schedule information from Microsoft Teams Shifts
Returns shift schedule data from the Teams Shifts feature, including shift times, assigned users, and shift notes.Use cases:
  • Let an agent check the current schedule before assigning tasks to team members
  • Notify on-call staff of incidents based on who is currently on shift
  • Summarize the week’s schedule and post it to a team channel
Key parameters: teamId, startDateTime, endDateTime (date range for shifts to retrieve).Output: An array of shift objects, each containing id, userId, sharedShift (with startDateTime, endDateTime, activities), and draftShift.

Advanced operations

Microsoft API Call

Make custom calls to any Microsoft Graph API endpoint for operations not covered by the pre-built tool steps
Gives you direct access to any Microsoft Graph API endpoint. Use this for operations not covered by the pre-built tool steps, or when you need fine-grained control over request parameters.Use cases:
  • Access Teams meeting transcripts or recordings
  • Manage team membership (add or remove members)
  • Retrieve files from a channel’s SharePoint document library
Key parameters: method (GET, POST, PATCH, DELETE), endpoint (Graph API path, e.g. /teams/{teamId}/members), body (JSON request body for write operations), params (query string parameters).Output: The raw JSON response from the Microsoft Graph API.
These tool steps use native OAuth and call Microsoft Graph API directly. If you encounter issues with a specific tool step, please contact support.

Example use cases

IT support bot

Monitor your IT support channel, search message history for similar past issues, and automatically respond to common technical questions. Escalate unresolved issues by creating a dedicated channel or messaging the on-call engineer.

Onboarding assistant

When a new hire joins, retrieve their team membership, create a dedicated onboarding channel, and send a personalized welcome message with links to relevant documentation and contacts.

Customer success agent

Search Teams messages for mentions of a specific customer, retrieve recent chat history for context, and post a summary of open action items to the account team’s channel.

Sales pipeline assistant

Post daily pipeline summaries to a sales channel, send direct messages to remind reps of follow-up tasks, and list team members to route new leads to the next available rep.

Shift handoff bot

At the end of each shift, retrieve current shift data, summarize open tickets or tasks from the channel, and send the outgoing team a handoff message with a status summary.

Compliance monitor

Periodically search messages for flagged terms, retrieve the surrounding conversation for context, and post a digest to a compliance team channel for review.

Best practices

Team and channel IDs are required parameters for most tool steps, but they are not human-readable. Rather than hardcoding IDs in your tool configuration, use the List Teams and List Channels tool steps to look up IDs at runtime. This makes your agent more flexible when teams or channels are renamed or reorganized.
Before deploying an agent that sends messages autonomously, set your Send Channel Message and Send Chat Message tool steps to “approval mode”. This lets you review and approve each outgoing message before it is sent, which is useful for catching formatting issues or unintended content during initial testing.
When your agent is triggered by a new message, use the Retrieve Chat Messages tool step to fetch recent conversation history before composing a reply. This gives the agent the context it needs to respond accurately rather than treating each message in isolation.
The Search Messages tool step is designed for querying historical message content. It is not suited for real-time monitoring — use a Teams trigger for that. Reserve Search Messages for cases where your agent needs to look up past decisions, approvals, or discussions before taking action.
Microsoft Graph API enforces rate limits that vary by subscription tier. Design your agent workflows to spread out API calls where possible and handle 429 Too Many Requests responses by waiting before retrying. Avoid polling patterns that make repeated API calls in quick succession.

Troubleshooting

This typically means the OAuth token does not have the permissions required for that operation. Reconnect your Microsoft account through the Integrations & API Keys page and ensure you grant all requested permissions during the OAuth flow. If your organization requires admin consent, ask your Microsoft 365 admin to approve the permission request.
The authenticated user must be a member of at least one Team for this tool step to return results. If the user is a guest in your tenant rather than a full member, Team visibility may be restricted. Verify the account is a direct member of the Teams you expect to see.
A 403 error on Send Channel Message usually means the authenticated user does not have permission to post in that channel. Check the channel’s moderation settings in Teams — some channels are configured to allow posts only from owners or specific roles.
Microsoft Graph search indexes Teams messages with a short delay after they are sent. If you are searching for a very recent message, wait a few minutes and try again. Search results are also scoped to content the authenticated user has access to — messages in private channels the user is not a member of will not appear.
Messages are returned in the order specified by the Graph API, which defaults to ascending createdDateTime. If you need the most recent messages first, sort the output by createdDateTime in descending order within your tool configuration.

Frequently asked questions (FAQs)

The Microsoft Teams integration in Relevance AI was built by Relevance AI, and is therefore supported by our team, not Microsoft. If you have a question or issue with using Microsoft Teams in Relevance AI, please reach out to our support team. If you have a question or issue that is only about Microsoft Teams, you can reach out to Microsoft support.
Microsoft Teams is a collaboration platform that combines workplace chat, video meetings, and file storage. Using it with Relevance AI allows you to automate responses to messages, trigger workflows from Teams conversations, and send automated messages to channels or chats, making your team communication more efficient.
Yes, you need a Microsoft account with access to Microsoft Teams. This integration is designed for Microsoft Teams for business and enterprise. You’ll need to authenticate your Microsoft account through Relevance AI to connect the integration.
Yes, you can connect multiple Microsoft accounts to your workspace through the Integrations & API Keys page. Each account can be used for different triggers and tool steps, which is useful for managing different Teams workspaces or separating different projects.
The integration requires permissions to read messages, send messages, and access team and channel information. The exact permissions are shown during the OAuth flow when you connect your account. Some operations — such as listing team members or accessing private channels — may require admin consent depending on your organization’s Microsoft 365 policies.
Yes, Teams triggers can monitor both channel messages and private chats, depending on your configuration. You can set up triggers for specific channels or direct message conversations.
Yes, you can configure trigger conditions such as keyword matching to filter which messages activate your workflow. This allows you to have your agent respond only to relevant messages rather than every message in a channel.
Set your message-sending tools to “approval mode” in the agent settings. This ensures your agent will always ask for permission before sending a Teams message. You can review the draft, make edits if needed, and then approve or reject the send action.
Yes, files shared in Teams channels are stored in SharePoint. You can use the Microsoft API Call tool step to access these files through the Graph API. Files are typically accessible via the channel’s associated SharePoint document library.
Pre-built tool steps (like Send Channel Message or List Teams) are designed for specific, common tasks and have simplified interfaces with guided inputs. The Microsoft API Call tool step gives you direct access to any Microsoft Graph API endpoint, allowing you to implement functionality not covered by pre-built steps.
Yes, Microsoft Graph API enforces rate limits. The specific limits depend on your Microsoft 365 subscription and the type of requests being made. Your agents should handle rate limiting gracefully. Microsoft returns a 429 Too Many Requests status code when limits are exceeded.
This integration is designed for Microsoft Teams for business and enterprise. Personal Microsoft accounts may have limited functionality. We recommend using a business or enterprise Microsoft 365 account for the best experience.
To remove the Microsoft Teams integration:
  1. Go to the Integrations & API Keys page from the sidebar
  2. Search for Microsoft (Teams, Outlook, SharePoint, OneDrive) from the list
  3. Click ”…” on the account you want to remove
  4. Click “Remove” and confirm your choice
Note: Removing the Microsoft integration will disable all triggers and tool steps using this account across Teams, Outlook, SharePoint, and OneDrive.