How to Connect Microsoft Teams MCP to an AI Agent
Auth setup
1. Azure Portal > App registrations > New registration. 2. Add API permissions: Microsoft Graph > Delegated (or Application for daemons). 3. Admin consent required for most Teams scopes. 4. Generate client secret or certificate. 5. Or use: npx @softeria/ms-365-mcp-server for managed setup.
Key facts
| Base URL | https://graph.microsoft.com/v1.0/ |
| API version | Microsoft Graph v1.0 (+ beta for preview features) |
| Auth | OAuth 2.0 via Microsoft Entra ID (formerly Azure AD). Supports authorization code flow, client credentials (app-only), and device code flow. Register app at Azure Portal > App registrations. Access token as Bearer. Official MCP via Teams AI Library (public preview). |
| Token URL | https://login.microsoftonline.com/{tenant}/oauth2/v2.0/token |
| Scopes | Chat.ReadWrite,ChannelMessage.Send,Team.ReadBasic.All,OnlineMeetings.ReadWrite,User.Read |
| Request body | application/json |
| Pagination | OData: @odata.nextLink in response for next page. $top parameter for page size (max varies by endpoint, often 999). |
| Rate limit | Per-app and per-tenant throttling. Teams messaging: ~30 requests/sec per app per tenant. Graph overall: ~10,000 requests per 10 min per app per tenant. HTTP 429 with Retry-After header. |
| Error format | JSON: {"error":{"code":"...","message":"...","innerError":{"date":"...","request-id":"..."}}} |
Key endpoints
| Method | Path | Description |
GET | /me/joinedTeams | List teams the user is a member of |
GET | /teams/{team-id}/channels | List channels in a team |
POST | /teams/{team-id}/channels/{channel-id}/messages | Post a message to a channel |
GET | /chats/{chat-id}/messages | List messages in a 1:1 or group chat |
POST | /chats/{chat-id}/messages | Send a chat message |
POST | /me/onlineMeetings | Create a Teams meeting |
GET | /users/{id}/presence | Get user presence (available, busy, etc.) |
Quickstart
POST /v1.0/teams/{team-id}/channels/{channel-id}/messages
Authorization: Bearer {token}
Content-Type: application/json
{"body":{"contentType":"html","content":"Hello from agent!"}}
Agent pitfalls & tips
- Always honor Retry-After header on 429 — Microsoft Graph enforces it strictly.
- For bot/daemon scenarios, use application permissions (client credentials flow) — no user login required.
- Teams messaging requires RSC (Resource-Specific Consent) or admin consent for most write scopes.
- Channel messages have a 28KB limit on body content. Use attachments for larger payloads.
- Adaptive Cards are the recommended rich message format — Teams renders them natively.
- Use webhooks (Incoming Webhook connector) for simple one-way posting without OAuth — not a Graph API call.
- Presence API is heavily rate-limited — batch with /communications/getPresencesByUserId for multiple users.
- Teams AI Library MCP (public preview) is the official agent path. Watch the docs for GA timing.
Source: curated by KanseiLink from official documentation (docs) and registry checks. Last reviewed: 2026-07-06. Specs change — verify against the official docs before production use.
Frequently Asked Questions
What is Microsoft Teams MCP's AEO score?
▼
Microsoft Teams MCP has an AEO score of 1.00 and is rated AAA (Best-in-class agent integration). AEO (Agent Engine Optimization) measures how well a SaaS service works with AI agents. Scores range from 0.00 to 1.00, with grades from AAA (best) to D (not agent-ready).
Is Microsoft Teams MCP AI-agent-ready?
▼
Microsoft Teams MCP is currently ✓ verified for AI agent use. It offers an official MCP (Model Context Protocol) server, which means AI agents can connect directly. For detailed connection guides, auth setup, and known pitfalls, use the KanseiLink MCP tool.
How does Microsoft Teams MCP compare to other Communication services?
▼
In the Communication category, Microsoft Teams MCP is rated AAA. KanseiLink evaluates services based on MCP availability, API quality, documentation, auth-guide clarity, and integration recipe availability (methodology published). Visit the full rankings at kansei-link.com to see how Microsoft Teams MCP compares.
How can I integrate Microsoft Teams MCP with an AI agent?
▼
The fastest way to integrate Microsoft Teams MCP with an AI agent is through KanseiLink MCP. Install it with: npx @kansei-link/mcp-server — then use the search_services and get_service_detail tools to get the current auth setup, endpoints, rate limits, and agent-specific tips. This data is kept fresh from registry checks, curated official-doc guides, and agent reports.
How do I authenticate with Microsoft Teams MCP?
▼
OAuth 2.0 via Microsoft Entra ID (formerly Azure AD). Supports authorization code flow, client credentials (app-only), and device code flow. Register app at Azure Portal > App registrations. Access token as Bearer. Official MCP via Teams AI Library (public preview). Setup: 1. Azure Portal > App registrations > New registration. 2. Add API permissions: Microsoft Graph > Delegated (or Application for daemons). 3. Admin consent required for most Teams scopes. 4. Generate client secret or certificate. 5. Or use: npx @softeria/ms-365-mcp-server for managed setup.
What are Microsoft Teams MCP's API rate limits?
▼
Per-app and per-tenant throttling. Teams messaging: ~30 requests/sec per app per tenant. Graph overall: ~10,000 requests per 10 min per app per tenant. HTTP 429 with Retry-After header.