Microsoft Teams
概览
作者提供的说明(英文原文)
Connect Claude to Microsoft Teams — read/send messages, list channels, search chats.
它能帮你做什么
我们还没有为它写通俗的介绍。下面是我们从注册中心读取到的事实。
- 连接方式: 在你的电脑上运行
- 传输方式: stdio
- 分类: 聊天与邮件
安装
选择你使用的 AI 应用,然后复制设置。
通过 2/2 项检查 · 在你的电脑上运行
第一步:你用哪个 AI?
选择你用的应用,步骤会显示在下方。
可连接 Claude,但需要先准备
需要先在电脑上安装 Node.js(只需一次) · 仅限电脑上的 Claude 应用(Windows 或 Mac),网页和手机不可用
打开电脑版 Claude 应用的设置文件
SettingsDeveloperEdit Config
粘贴这些设置并保存文件
{ "mcpServers": { "teams": { "command": "npx", "args": [ "-y", "microsoft-teams-mcp-server" ] } } }退出 Claude 再重新打开
试一试
用 Microsoft Teams 告诉我你能帮我做什么,然后做一件给我看✓ 如果 Claude 说正在使用 Microsoft Teams,或回答中出现 Microsoft Teams 的工具名称,就表示连接成功
菜单名称已于 2026年11月11日 对照 Anthropic 帮助页面核实 · 你的界面可能因版本略有不同
ChatGPT 暂时无法连接 Microsoft Teams
Microsoft Teams 需要安装在你的电脑上,而 ChatGPT 只能连接在网上运行的服务器
你可以改用这些方式
A · 使用能连接 Microsoft Teams 的应用
- 需要先在电脑上安装 Node.js(只需一次) · 仅限电脑上的 Claude 应用(Windows 或 Mac),网页和手机不可用
- 需要先在电脑上安装 Node.js(只需一次)
- 需要先在电脑上安装 Node.js(只需一次)
- 需要先在电脑上安装 Node.js(只需一次)
B · 聊天与邮件 类中能连接 ChatGPT 的其他服务器
从同类中使用较多的里挑选,仅限用地址即可连接、无需密钥的
- Inbox Zero✓ ChatGPT
- Agent-Native Chat✓ ChatGPT
- draw.io✓ ChatGPT
可连接 Claude Code,但需要先准备
需要先在电脑上安装 Node.js(只需一次)
打开终端
Mac:按 Command+空格,输入 Terminal · Windows:打开 PowerShell
粘贴这条命令并按 Enter
claude mcp add teams -- npx -y microsoft-teams-mcp-server在 Claude Code 中输入 /mcp
应能看到 Microsoft Teams 在列表中并显示已连接
试一试
用 Microsoft Teams 告诉我你能帮我做什么,然后做一件给我看✓ 如果 Claude Code 说正在使用 Microsoft Teams,或回答中出现 Microsoft Teams 的工具名称,就表示连接成功
菜单名称已于 2026年11月11日 对照 Anthropic 帮助页面核实 · 你的界面可能因版本略有不同
可连接 Cursor,但需要先准备
需要先在电脑上安装 Node.js(只需一次)
在 Cursor 中以 Agent 模式打开 AI 聊天
试一试
用 Microsoft Teams 告诉我你能帮我做什么,然后做一件给我看✓ 如果 Cursor 说正在使用 Microsoft Teams,或回答中出现 Microsoft Teams 的工具名称,就表示连接成功
菜单名称已于 2026年11月11日 对照 Cursor 帮助页面核实 · 你的界面可能因版本略有不同
可连接 VS Code,但需要先准备
需要先在电脑上安装 Node.js(只需一次)
在 VS Code 中以 Agent 模式打开 AI 聊天
试一试
用 Microsoft Teams 告诉我你能帮我做什么,然后做一件给我看✓ 如果 VS Code 说正在使用 Microsoft Teams,或回答中出现 Microsoft Teams 的工具名称,就表示连接成功
菜单名称已于 2026年11月11日 对照 VS Code 帮助页面核实 · 你的界面可能因版本略有不同
开发者专用:终端命令和 JSON 设置
安装在电脑上
Claude Code
claude mcp add teams -- npx -y microsoft-teams-mcp-serverClaude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"teams": {
"command": "npx",
"args": [
"-y",
"microsoft-teams-mcp-server"
]
}
}
}Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"teams": {
"command": "npx",
"args": [
"-y",
"microsoft-teams-mcp-server"
]
}
}
}VS Code (mcp.json)
{
"servers": {
"teams": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"microsoft-teams-mcp-server"
]
}
}
}这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。
一览
哪些应用可以使用它
依据这个服务器的连接方式和各应用自己的文档,检查于 2026年11月10日。
在你的电脑上运行,适用于
ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast
它能做什么
它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。
基础检查i
我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月11日
- ✓ 通过
作者与仓库一致
注册名称已通过 GitHub 账户 SurgeEnterpriseAI 验证,该账户拥有此仓库
- ✓ 通过
仍在维护
代码最后更新于10天前
- … 尚未检查
有许可证
我们还没有从 GitHub 读取这个仓库
- – 不适用
端点有响应
它在你的电脑上运行,没有互联网端点
- – 不适用
使用 OAuth 登录
在你的电脑上运行,改用本地设置
- … 尚未检查
工具描述中没有隐藏指令
它在你的电脑上运行;我们只能读取互联网端点的工具列表
讨论
提问、分享技巧或报告无法使用。按“有帮助”数量排序。
用户评价
还没有评价
与“聊天与邮件”中的其他服务器比较i
- 星标数多于此分类中其他 1948 个服务器的 89%
- 发布到注册中心的时间比此分类中其他 1948 个服务器的 5% 更新
- 基础检查结果等于或优于此分类中其他 1948 个服务器的 100%
与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。
常见问题
Microsoft Teams 安全吗?
它在 2 项适用的基础检查中通过了 2 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。
它需要哪些密钥或代码?
注册中心没有列出必需的密钥,不过有些服务器会在首次使用时要求你登录。
它在我的电脑上运行还是在云端?
它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。
它还在维护吗?
GitHub 仓库最后更新于10天前,最新版本(1.0.0)于7个月前进入注册中心。
哪些应用可以使用它?
支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Node.js。
有什么可以替代它?
同一分类中有:Inbox Zero, Agent-Native Chat, draw.io
替代选择
同一分类中其他作者的服务器,按星标数排序。
如何看卡片:↓ 每周下载量i★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i
Agent-Native Chat
Minimal chat-first app with durable threads, actions, and the app-agent loop
draw.io
Create draw.io diagrams in chat from Mermaid or XML, shown live and interactive. 10,000+ shapes.
作者的 README
打开 README
按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。
Teams MCP Server
Let Claude read and send your Microsoft Teams messages. An open-source MCP server that connects Claude Code, Claude Desktop and Claude Cowork to Microsoft Teams: list your teams and channels, read channel and chat messages, search across Teams, and post or reply — all by asking Claude in plain English.
- What it does: gives Claude 11 Teams tools through Microsoft Graph, using *your own* Microsoft 365 sign-in. Claude sees only what you can already see in Teams. Messages pass through; nothing is stored except your sign-in token on your machine.
- Who it's for: people who live in Teams and use Claude — developers, team leads, support and ops people who want "summarise #standup since Monday" or "reply to Priya's question in #release" without switching windows. Also teams that want to host one shared Teams connector for everyone in their company.
- Cost: free and MIT-licensed. You need a Microsoft 365 work or school account and permission to register an app in Azure (or an admin who does it for you once).
▶ Watch the 76-second walkthrough: Teams MCP Server — how it works (captions on; transcript)
Install in 3 steps (Claude Code, on your own computer)
- Register an app in Azure (5 minutes, once). Azure Portal → *App registrations* → *New registration* → any name, *Accounts in any organizational directory*, redirect URI type Web =
http://localhost:3333/callback. Then add a client secret and the delegated Microsoft Graph permissions listed in Azure AD App Registration below. Copy the client ID and secret. - Add the server to Claude:
claude mcp add teams -e TEAMS_CLIENT_ID=<your-client-id> -e TEAMS_CLIENT_SECRET=<your-secret> -- npx -y microsoft-teams-mcp-server
- Sign in once. Start Claude and ask *"List my Teams."* A browser window opens; sign in with your Microsoft work account. Done — the token is cached, so you won't be asked again.
Using Claude Desktop instead? Put the same command and env in claude_desktop_config.json (see Claude Desktop). Want one server for your whole company? See Self-host.
Using it (plain English)
You don't call the tools yourself — you just ask Claude, and Claude picks the right one. Things you can say:
| You say | What happens |
|---|---|
| "Which Teams am I in?" | Lists your teams. |
| "What channels does the Platform team have?" | Lists that team's channels. |
| "Summarise what happened in #standup today." | Reads recent channel messages and summarises them. |
| "Show me the replies to Ravi's deploy message." | Reads a thread's replies. |
| "Find every message that mentions the invoice bug." | Searches across all your Teams. |
| "What did Anita say in our chat yesterday?" | Lists your chats and reads the one with Anita. |
| "Post 'Release 4.2 is live' in #announcements." | Sends a channel message. |
| "Reply in that thread: 'Fixed in PR 812.'" | Replies in a channel thread. |
| "Send Anita a chat: 'Running 10 minutes late.'" | Sends a chat message. |
Good to know:
- Your access, nothing more. Claude uses your sign-in, so it can only see teams, channels and chats you're in. Each person who connects signs in with their own account.
- You approve what gets sent. Claude asks permission before each tool call unless you've allowed that tool. A good setup: allow the read and search tools, and keep the three send/reply tools on "ask" so you see every message before it posts.
- Sign-in lasts. The token is saved in
.data/tokens(local) and refreshed silently. Delete that folder to sign out. - Search needs a work account. Microsoft search across Teams doesn't work for personal Microsoft accounts.
- If something fails, ask Claude "what was the error?" — the server returns Microsoft's own message (for example, a missing permission or admin consent).
How It Works
┌─────────────┐ Click "Connect" ┌──────────────────────┐
│ Claude User │ ──────────────────────► │ Teams MCP Server │ │ (Cowork/ │ │ (hosted by you or │ │ Desktop/ │ SSE/MCP Protocol │ your company) │ │ 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.
Features
- One-click connect — visit
/connect, sign in with Microsoft, done - Multi-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 for your company:
- 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 build
2. Azure AD App Registration
- Go to Azure Portal → App registrations → New registration
- Name:
Teams MCP Server - Supported account types: "Accounts in any organizational directory (Any Azure AD directory - Multitenant)"
- Redirect URI: Web →
https://your-server.com/auth/callback(hosted) and/orhttp://localhost:3333/callback(local STDIO sign-in) - Click 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.js
4. 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
Quickest: claude mcp add as in Install in 3 steps. Or add to your .mcp.json from a clone:
{
"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.
Claude Desktop
In claude_desktop_config.json:
{
"mcpServers": { "teams": { "command": "npx", "args": ["-y", "microsoft-teams-mcp-server"], "env": { "TEAMS_CLIENT_ID": " ", "TEAMS_CLIENT_SECRET": " ", "TRANSPORT_MODE": "stdio" } } } }
Available Tools
| Tool | What it does |
|---|---|
teams_list_teams | List all your Teams |
teams_list_channels | List channels in a team |
teams_read_channel_messages | Read recent channel messages |
teams_send_channel_message | Send a message to a channel |
teams_reply_to_message | Reply in a channel thread |
teams_read_message_replies | Read thread replies |
teams_list_chats | List your DMs and group chats |
teams_read_chat_messages | Read messages from a chat |
teams_send_chat_message | Send a direct/group chat message |
teams_search_messages | Search messages across all Teams |
teams_get_profile | 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 |
|---|---|---|---|
TEAMS_CLIENT_ID | Yes | — | Azure AD app client ID |
TEAMS_CLIENT_SECRET | Yes | — | Azure AD client secret |
TEAMS_AUTHORITY | No | common | common for multi-tenant, or a specific tenant ID |
TRANSPORT_MODE | No | auto | auto, stdio, or http |
PORT | No | 3000 | HTTP server port |
BASE_URL | No | http://localhost:3000 | Public URL |
REDIRECT_URI | No | {BASE_URL}/auth/callback | OAuth callback URL |
TOKEN_STORE_PATH | No | ./.data/tokens | Token cache directory |
LOG_LEVEL | No | info | Logging level |
For AI assistants
A short, structured summary for LLMs and AI search lives in docs/llms.md.
License
MIT — LICENSE
Contributing
Issues and PRs welcome. Built by SurgeEnterpriseAI — Surge Software Solutions, Bengaluru.