Teams MCP Server
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Teams MCP Serverlist recent messages in the General channel"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Teams MCP Server
The first open-source Microsoft Teams connector for Claude. Any Microsoft 365 user can connect — just sign in with your work account. No setup, no credentials, no self-hosting required.
Read messages, list channels, search across Teams, send messages — all from Claude Code, Claude Desktop, or Claude Cowork.
Built by SurgeEnterpriseAI.
How It Works
┌─────────────┐ Click "Connect" ┌──────────────────────┐
│ Claude User │ ──────────────────────► │ Teams MCP Server │
│ (Cowork/ │ │ (hosted by Surge) │
│ Desktop/ │ SSE/MCP Protocol │ │
│ Code) │ ◄─────────────────────► │ ┌────────────────┐ │
└─────────────┘ │ │ OAuth (common) │ │
│ │ Any M365 user │ │
User signs in with their │ │ can sign in │ │
own Microsoft account │ └───────┬────────┘ │
─────────────────────► │ │ │
│ ┌───────▼────────┐ │
│ │ Microsoft │ │
│ │ Graph API │ │
│ └────────────────┘ │
└──────────────────────┘The user connects their own Microsoft 365 account. They see their own teams, their own channels, their own messages. Each user's tokens are isolated. The server is the bridge — it never stores messages, just passes them through.
Related MCP server: Microsoft 365 MCP Server
Features
One-click connect — visit
/connect, sign in with Microsoft, doneMulti-tenant — any Microsoft 365 organization, any user
11 tools — teams, channels, messages, chats, search, profile
Dual transport — STDIO for Claude Code, HTTP/SSE for Cowork & remote
Multi-user — each session gets isolated OAuth tokens
Auto-detect — picks the right transport based on launch method
Token caching — silent refresh, no re-login every session
Retry logic — automatic retries on throttled Graph API calls
TypeScript — fully typed, clean architecture, MIT licensed
For Users: Connect in 1 Click
If someone is already hosting this server (e.g., on https://teams-mcp.surgeai.com):
Claude asks you to connect Microsoft Teams
You click the auth link
Sign in with your Microsoft work account
Done — Claude can now read your Teams
No API keys, no Azure portal, no setup.
For Developers: Self-Host
1. Clone & Install
git clone https://github.com/SurgeEnterpriseAI/teams-mcp-server.git
cd teams-mcp-server
npm install
npm run build2. Azure AD App Registration
Go to Azure Portal → App registrations → New registration
Name:
Teams MCP ServerSupported account types: "Accounts in any organizational directory (Any Azure AD directory - Multitenant)"
Redirect URI: Web →
https://your-server.com/auth/callbackClick Register
Configure:
Certificates & secrets → New client secret → copy the Value
API Permissions → Add Delegated (Microsoft Graph):
ChannelMessage.Read.All,ChannelMessage.SendChat.Read,Chat.ReadWrite,ChatMessage.SendTeam.ReadBasic.All,Channel.ReadBasic.AllUser.Read
Click Grant admin consent (for your own tenant; other tenants consent on first login)
3. Configure & Deploy
cp .env.example .env
# Set TEAMS_CLIENT_ID, TEAMS_CLIENT_SECRET
# Set BASE_URL and REDIRECT_URI to your production URL
# TEAMS_AUTHORITY=common (multi-tenant, default)Deploy to Railway, Render, Azure App Service, or any Node.js host:
# Railway
railway login && railway init && railway up
# Or Azure
az webapp up --name teams-mcp-server --runtime "NODE:20-lts"
# Or just run directly
TRANSPORT_MODE=http node dist/index.js4. Submit to MCP Registry
Once deployed and tested, submit your server URL to Anthropic's MCP connector registry. Users will then see "Microsoft Teams" as a connect option in Claude Cowork — just like Slack and Gmail.
For Claude Code Users: Local STDIO Mode
Add to your .mcp.json:
{
"mcpServers": {
"teams": {
"command": "node",
"args": ["/path/to/teams-mcp-server/dist/index.js"],
"cwd": "/path/to/teams-mcp-server"
}
}
}First run will open your browser for Microsoft login. After that, tokens are cached.
Available Tools
Tool | What it does |
| List all your Teams |
| List channels in a team |
| Read recent channel messages |
| Send a message to a channel |
| Reply in a channel thread |
| Read thread replies |
| List your DMs and group chats |
| Read messages from a chat |
| Send a direct/group chat message |
| Search messages across all Teams |
| Get your Microsoft 365 profile |
Architecture
src/
├── index.ts Main entry (auto-detects transport)
├── config.ts Central configuration
├── logger.ts Structured logging
├── types.ts TypeScript interfaces
├── sessions.ts Multi-user session manager
├── auth/
│ ├── oauth.ts MSAL OAuth (multi-tenant, per-user)
│ └── token-store.ts Persistent token cache
├── graph/
│ ├── client.ts Graph HTTP client with retries
│ ├── teams.ts Teams & channels API
│ ├── messages.ts Channel messages API
│ ├── chats.ts DM & group chat API
│ └── search.ts Search & profile API
├── mcp/
│ ├── server.ts MCP server factory
│ └── tools/ 11 tool definitions
├── transport/
│ ├── stdio.ts STDIO (Claude Code)
│ └── http.ts Express + SSE (Cowork / remote)Environment Variables
Variable | Required | Default | Description |
| Yes | — | Azure AD app client ID |
| Yes | — | Azure AD client secret |
| No |
|
|
| No |
|
|
| No |
| HTTP server port |
| No |
| Public URL |
| No |
| OAuth callback URL |
| No |
| Token cache directory |
| No |
| Logging level |
License
MIT — LICENSE
Contributing
Issues and PRs welcome. Built by SurgeEnterpriseAI.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceConnects Claude to Microsoft Outlook through the Microsoft Graph API, enabling email management (list, search, read, send) and calendar operations (list, create, accept, decline, delete events) via OAuth 2.0 authentication.1MIT
- FlicenseNot gradedqualityCmaintenanceProvides Claude Desktop and Claude Code with access to Microsoft 365 email and calendar services via the Microsoft Graph API. It enables users to manage emails, search folders, schedule calendar events, and check availability through natural language commands.
- AlicenseNot gradedqualityBmaintenanceConnects Claude with Microsoft 365 services such as Email, Calendar, Teams, OneDrive, and more through the Microsoft Graph API.4616MIT
- AlicenseNot gradedqualityCmaintenanceConnects Claude with Microsoft 365 services including Outlook, OneDrive, and Power Automate, enabling email, calendar, files, and flow management through natural language.34423MIT
Related MCP Connectors
Drive your real WhatsApp inbox from Claude — send, reply, label, assign, and triage via TimelinesAI.
Connect Claude to Fathom meeting recordings, transcripts, and summaries
WHOOP recovery, strain, sleep and workouts in Claude via official WHOOP OAuth. Free, open source.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/SurgeEnterpriseAI/teams-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server