Everything an AI agent can do with the Microsoft Teams API.

A reference guide for building AI agents: every method, how to authenticate, and the permissions each one needs.

Endpoints19
API versionv1.0
Last updated23 June 2026
Orientation

How the Microsoft Teams API works.

The Microsoft Teams API is how an app or AI agent works with Microsoft Teams: listing teams and channels, reading and posting channel messages, reading chats and their messages, and managing team members. Access is granted through a Microsoft Entra app and a set of Microsoft Graph permissions, either acting as a signed-in user or acting as the app itself, and an agent reaches only the teams, channels, and chats those permissions allow. Microsoft Graph can also push a change to a notification URL when a message is created, updated, or deleted.

19Endpoints
5Capability groups
11Read
8Write
11Permissions
Authentication
Teams is reached through Microsoft Graph, so an app authenticates with Microsoft Entra (Azure AD) and sends an OAuth 2.0 access token as 'Authorization: Bearer '. A token is either delegated, acting on behalf of a signed-in user, or application, acting as the app itself with administrator consent. Personal Microsoft accounts are not supported for these methods, only work or school accounts.
Permissions
Each method needs a specific Microsoft Graph permission, such as Team.ReadBasic.All, Channel.ReadBasic.All, ChannelMessage.Read.All, ChannelMessage.Send, Chat.Read, or ChatMessage.Send. Many application permissions come in two forms: a tenant-wide one (ending .All) that reaches every team or chat, and a resource-specific one (ending .Group or .Chat) granted to a single team or chat through resource-specific consent. Posting channel and chat messages is delegated only; the matching application permission, Teamwork.Migrate.All, is for importing past messages, not live posting.
Versioning
Microsoft Graph does not use dated version strings. It serves two named endpoints: v1.0, the generally available surface meant for production, and beta, which carries newer, unstable features that can change without notice. Notable changes are recorded in the Microsoft Graph changelog rather than by minting a new version.
Data model
A team is backed by a Microsoft 365 group and contains channels; a channel holds chatMessage items, each of which can have replies. Separately, chats hold chatMessage items for one-on-one, group, and meeting conversations outside any team. Members are represented by conversationMember entries on a team. Identifiers are opaque strings, and a channel id looks like 19:...@thread.tacv2.
Connect & authenticate

Connection & authentication methods.

How an app or AI agent connects to Microsoft Teams determines what it can reach. Teams is part of Microsoft Graph, so an agent connects through a Microsoft Entra app registration and the Graph permissions it is granted.

Ways to connect

Microsoft Graph REST API

Teams is part of Microsoft Graph, which answers at https://graph.microsoft.com. The generally available surface is the v1.0 endpoint; a separate beta endpoint carries newer, unstable features.

Best forConnecting an app or AI agent to Microsoft Teams.
Governed byThe Microsoft Entra app and the Graph permissions it carries.
Docs ↗

Microsoft MCP Server for Enterprise (Model Context Protocol)

Microsoft's first-party MCP server translates natural-language requests into read-only Microsoft Graph calls, honoring the caller's roles, granted permissions, and throttling limits. It is in public preview and currently focuses on Microsoft Entra identity and directory read scenarios rather than full Teams messaging.

Best forConnecting an AI agent to Microsoft Graph for read-only queries.
Governed byThe signed-in user's roles and the granted Graph permissions.
Docs ↗

Change notifications

An app creates a subscription for a channel, a chat, or a whole tenant, and Microsoft Graph posts each create, update, or delete to a notification URL. Notifications can carry the encrypted message payload when an encryption certificate is supplied.

Best forConnecting an app or AI agent to Microsoft Teams.
Governed byThe Microsoft Entra app and the Graph permissions it carries.
Docs ↗
Authentication

Delegated permissions (acting as a user)

A delegated token acts on behalf of a signed-in user, so the app can do only what that user can do. Posting channel and chat messages is supported only this way, through ChannelMessage.Send and ChatMessage.Send.

TokenOAuth 2.0 user access token
Best forActing as a person, and for sending messages
Docs ↗

Application permissions (acting as itself)

An application token acts as the app with no user present, granted by an administrator. It suits background automation that reads across a tenant, but it cannot post new channel or chat messages, since live sending is delegated only.

TokenOAuth 2.0 app-only access token
Best forBackground reads across a tenant
Docs ↗

Resource-specific consent

Resource-specific consent grants an application permission scoped to a single team or chat rather than the whole tenant, through permissions whose names end in .Group or .Chat, such as ChannelMessage.Read.Group. A team owner consents when the app is installed.

TokenOAuth 2.0 app-only access token
Best forLeast-privilege access to one team or chat
Docs ↗
Endpoint reference

Every Microsoft Teams API method.

Filter by method, access, or permission, or search any path. Select a row for version detail, rate limits, the related webhook event, and the source.

MethodEndpointWhat it doesAccessPermissionVersion

Teams

List all teams in an organization, list the teams a user has joined, read a single team, and create a team from a Microsoft 365 group.4

Returns only id, displayName, description, and visibility; other properties come back null. Use Get team for the rest. Same permission for delegated and application.

Acts onteam
Permission (capability)Team.ReadBasic.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

This route applies only to Microsoft Teams, not Microsoft 365 groups in general. Delegated only.

Acts onteam
Permission (capability)Team.ReadBasic.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Reading full settings needs TeamSettings.Read.All. The application form TeamSettings.Read.Group uses resource-specific consent, where an app is granted access to one team at a time rather than all of them.

Acts onteam
Permission (capability)Team.ReadBasic.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Every team is backed by a Microsoft 365 group, so a team is created by adding a team to a group that has at least one owner. A newly made group can return 404 until it replicates, so a retry is expected.

Acts onteam
Permission (capability)Group.ReadWrite.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Channels

List the channels in a team, read a single channel, and create a new channel.3

Private and shared channels appear only to members. The application form ChannelSettings.Read.Group uses resource-specific consent, scoped to one team.

Acts onchannel
Permission (capability)Channel.ReadBasic.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Reading channel settings beyond the basic fields needs ChannelSettings.Read.All. The application form ChannelSettings.Read.Group uses resource-specific consent.

Acts onchannel
Permission (capability)Channel.ReadBasic.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

The application form Channel.Create.Group uses resource-specific consent, scoped to one team rather than the whole tenant.

Acts onchannel
Permission (capability)Channel.Create
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Channel messages

List the messages in a channel, read a single message, post a new message, and reply to a message.4

Returns up to 20 messages per page, extendable to 50; use $expand=replies for replies. The application form ChannelMessage.Read.Group uses resource-specific consent, scoped to one team.

Acts onchatMessage
Permission (capability)ChannelMessage.Read.All
VersionAvailable since the API’s base version
Webhook eventchannel-message
Rate limitStandard limits apply

The application form ChannelMessage.Read.Group uses resource-specific consent, scoped to one team.

Acts onchatMessage
Permission (capability)ChannelMessage.Read.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Sending a message is supported only as a signed-in user with the delegated ChannelMessage.Send permission. The only application permission here is Teamwork.Migrate.All, which is for importing past messages, not posting new ones.

Acts onchatMessage
Permission (capability)ChannelMessage.Send
VersionAvailable since the API’s base version
Webhook eventchannel-message
Rate limitStandard limits apply

As with posting a new message, replying is delegated only. The application permission Teamwork.Migrate.All is for migration, not live replies.

Acts onchatMessage
Permission (capability)ChannelMessage.Send
VersionAvailable since the API’s base version
Webhook eventchannel-message
Rate limitStandard limits apply

Chats & chat messages

List a user's chats, read a single chat, list the messages in a chat, and send a chat message.4

Chat.ReadBasic returns the chat list without message content; Chat.Read adds messages. The /chats route lists the signed-in user's chats; the application form uses Chat.ReadBasic.All on /users/{id}/chats.

Acts onchat
Permission (capability)Chat.ReadBasic
VersionAvailable since the API’s base version
Webhook eventchat-message
Rate limitStandard limits apply

The application form Chat.ReadBasic.All can read any chat in the tenant, so it reaches far more than the delegated form, which sees only the signed-in user's chats.

Acts onchat
Permission (capability)Chat.ReadBasic
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Reading message content needs Chat.Read, not the lighter Chat.ReadBasic. The application form is Chat.Read.All across the tenant.

Acts onchatMessage
Permission (capability)Chat.Read
VersionAvailable since the API’s base version
Webhook eventchat-message
Rate limitStandard limits apply

Sending is delegated only with ChatMessage.Send; this method cannot create a new chat, only post to an existing one. The application permission Teamwork.Migrate.All is for migration, not live sending.

Acts onchatMessage
Permission (capability)ChatMessage.Send
VersionAvailable since the API’s base version
Webhook eventchat-message
Rate limitStandard limits apply

Members

List the members of a team, add a member, update a member's role, and remove a member.4

The application form TeamMember.Read.Group uses resource-specific consent, scoped to one team.

Acts onconversationMember
Permission (capability)TeamMember.Read.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

The application form TeamMember.ReadWrite.Group uses resource-specific consent, scoped to one team.

Acts onconversationMember
Permission (capability)TeamMember.ReadWrite.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Changing a member to owner grants them control over the team. The application form TeamMember.ReadWrite.Group uses resource-specific consent.

Acts onconversationMember
Permission (capability)TeamMember.ReadWrite.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

The application form TeamMember.ReadWrite.Group uses resource-specific consent, scoped to one team.

Acts onconversationMember
Permission (capability)TeamMember.ReadWrite.All
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply
No endpoints match those filters.
Webhooks

Webhook events.

Microsoft Graph can notify an app or AI agent when a message is created, updated, or deleted in a channel or chat, instead of the app repeatedly asking. The agent creates a subscription for the chosen resource, and Graph posts each change to a notification URL.

EventWhat it signalsTriggered by
chatMessage (channel)Fires when a message or reply is created, updated, or deleted in a channel. An app subscribes to /teams/{team-id}/channels/{channel-id}/messages, or to /teams/getAllMessages for every channel in the tenant./teams/{team-id}/channels/{channel-id}/messages
/teams/{team-id}/channels/{channel-id}/messages
/teams/{team-id}/channels/{channel-id}/messages/{message-id}/replies
chatMessage (chat)Fires when a message is created, updated, or deleted in a chat. An app subscribes to /chats/{chat-id}/messages, to /users/{user-id}/chats/getAllMessages, or to /chats/getAllMessages for every chat in the tenant./me/chats
/chats/{chat-id}/messages
/chats/{chat-id}/messages
No events match that search.
Rate limits & pagination

Rate limits, pagination & request size.

Microsoft Graph limits how fast an app or AI agent can call, through a request ceiling measured over a short window that applies across the whole service, with extra service limits for Teams on top.

Request rate

Microsoft Graph applies a service-wide ceiling of 130,000 requests within any 10-second window for a single app across all tenants, and Teams adds its own service limits on top. Going over returns 429 Too Many Requests with a Retry-After header that gives the number of seconds to wait, and the x-ms-throttle-scope and x-ms-throttle-limit-percentage headers report what was throttled and how close the app is to the limit. Polling a resource for changes is allowed only once per day; for anything more frequent, a change-notification subscription should be used instead.

Pagination

List endpoints page with an @odata.nextLink URL in the response, which should be followed until it is absent rather than built by hand. Channel messages return up to 20 per page, extendable to 50 with $top, and replies can be pulled in with $expand=replies.

Request size

Requests and responses are JSON. Message bodies can be plain text or HTML, and a channel message can carry inline images and other hosted content. Listing a single channel message with $expand=replies can return up to 1,000 replies per page.

Errors

Status codes & error handling.

The status codes an agent should handle, and what to do about each.

StatusCodeMeaningWhat to do
401UnauthorizedThe access token is missing, invalid, or expired.Acquire a fresh token from Microsoft Entra and send it in the Authorization header.
403ForbiddenThe token is valid but lacks the permission the call needs, or an administrator has not consented to it. Trying to post a channel or chat message with an application token also lands here, since live sending is delegated only.Grant the required Graph permission, get admin consent, or switch to a delegated token for sending messages.
404Not FoundThe team, channel, chat, or message does not exist, or the token cannot see it. A team created less than 15 minutes ago can also return 404 while the underlying group replicates.Confirm the id and the token's access, and for a brand-new team, retry after a short delay.
409ConflictThe request conflicts with the current state. When importing a message, a createdDateTime that already exists in the target channel down to the millisecond returns this.Adjust the conflicting value, such as the createdDateTime, and retry.
429Too Many RequestsA throttling limit was exceeded, either the service-wide Microsoft Graph ceiling or a Teams service limit.Wait for the number of seconds in the Retry-After header before sending the request again.
503Service UnavailableThe service is temporarily unavailable or overloaded.Back off and retry, honoring the Retry-After header when it is present.
Versioning & freshness

Version history.

Microsoft Graph serves Teams under the named endpoint v1.0, the generally available surface. It does not use dated version strings; changes ship continuously and are recorded in the Graph changelog.

Version history

What changed, and when

Latest versionv1.0
2026-04
Channel-level app management and channel pagination (April 2026)

Microsoft Graph made channel-level Teams app management generally available on v1.0, letting an app list, get, enable, and disable apps within a single channel. The same update added @odata.nextLink pagination to the channel-listing methods to support larger channel counts, and removed the payment-model parameters and guidance from the Teams export APIs.

What changed
  • List, get, enable, and disable Teams apps at the channel level
  • List channels, list incomingChannels, and list allChannels gained @odata.nextLink pagination
  • Removed the model parameters and payment-model guidance from the Teams export APIs
2026-01
Reply with a quote (January 2026)

The replyWithQuote method on the chatMessage resource became generally available on v1.0, letting an app reply to one or more existing chat messages while quoting them.

What changed
  • Added replyWithQuote on chatMessage to reply with a quote to one or more chat messages
v1.0Current version
Generally available endpoint

The v1.0 endpoint is the generally available, production surface of Microsoft Graph, including the Teams resources for teams, channels, channel messages, chats, chat messages, and members. Microsoft Graph does not use dated version strings; new and changing features are tracked in the Microsoft Graph changelog, and unstable features live on the separate beta endpoint until they graduate to v1.0.

What changed
  • Teams, channels, channel messages, chats, chat messages, and members are generally available on v1.0
  • Change notifications for channel and chat messages support create, update, and delete, with optional encrypted resource data
  • Resource-specific consent permissions (.Group and .Chat) scope application access to a single team or chat

A separate beta endpoint carries newer, unstable features and should not be used in production.

Microsoft Graph changelog ↗
Questions

Microsoft Teams API, answered.

Can an AI agent post a message to a channel using application (app-only) permissions?+
No. Posting a new channel or chat message, and replying to one, is supported only with delegated permissions that act as a signed-in user, through ChannelMessage.Send and ChatMessage.Send. The only application permission on those methods is Teamwork.Migrate.All, which exists to import historical messages during a migration, not to post new ones. An agent that needs to post must act on behalf of a user.
What is the difference between a .All permission and a .Group permission?+
A permission ending in .All, such as ChannelMessage.Read.All, is tenant-wide: it reaches every team or chat in the organization. A permission ending in .Group or .Chat, such as ChannelMessage.Read.Group, is granted to a single team or chat through resource-specific consent, where a team owner consents when the app is installed. The .Group form is the least-privilege choice when an agent only needs one team.
How does an agent receive new messages without polling?+
By creating a change-notification subscription. An app subscribes to a channel (/teams/{team-id}/channels/{channel-id}/messages), a chat (/chats/{chat-id}/messages), or a whole tenant (/teams/getAllMessages or /chats/getAllMessages), and Microsoft Graph posts each create, update, or delete to a notification URL. With an encryption certificate, the notification can carry the message itself, avoiding a follow-up read. Polling the same resource is allowed only once per day.
What are the rate limits?+
Microsoft Graph applies a service-wide ceiling of 130,000 requests in any 10-second window for one app across all tenants, with extra Teams service limits on top. Exceeding a limit returns 429 Too Many Requests with a Retry-After header giving the seconds to wait. The x-ms-throttle-scope and x-ms-throttle-limit-percentage headers indicate what was throttled and how close the app is to the limit.
Does Microsoft Teams have an official MCP server?+
Microsoft publishes a first-party MCP server, the Microsoft MCP Server for Enterprise, which turns natural-language requests into read-only Microsoft Graph calls while honoring the caller's roles, granted permissions, and throttling limits. It is in public preview and currently focuses on Microsoft Entra identity and directory reads rather than full Teams messaging, so it is a read-only path today, not a way to post messages.
Why do some methods not work with a personal Microsoft account?+
The Teams methods in Microsoft Graph support only work or school accounts (organizational Microsoft Entra accounts). Delegated permissions for personal Microsoft accounts are listed as not supported across these endpoints, because Teams data lives in an organization's Microsoft 365 tenant.
Related

More communication API guides for agents

What is Bollard AI?

Control what every AI agent can do in Microsoft Teams.

Bollard AI sits between a team's AI agents and Microsoft Teams. Grant each agent exactly the access it needs, read or write, channel by channel, and every call is checked and logged.

  • Set read, write, or full access per agent, never a shared Microsoft 365 app secret.
  • Denied by default, so an agent reaches only the teams and channels that have been explicitly allowed.
  • Every call recorded in plain English: who, what, where, and the decision.
Microsoft Teams
Comms Agent
Read channel messages ResourceOffReadFull use
Post to a channel ActionOffReadFull use
Read private chats ResourceOffReadFull use
Create teams and channels ActionOffReadFull use
Per-agent access, set in Bollard AI, not in Microsoft Teams