by floriscornel
Integrate Microsoft Teams with Microsoft Graph API to manage chats, messages, and users securely using device code authe
Integrates with Microsoft Teams through Graph API to read and send messages, search users, browse teams and channels. Uses secure OAuth authentication to access your organization's Teams data.
Microsoft Teams is a community-built MCP server published by floriscornel that provides AI assistants with tools and capabilities via the Model Context Protocol. Integrate Microsoft Teams with Microsoft Graph API to manage chats, messages, and users securely using device code authe It is categorized under productivity, communication. This server exposes 19 tools that AI clients can invoke during conversations and coding sessions.
You can install Microsoft Teams in your AI client of choice. Use the install panel on this page to get one-click setup for Cursor, Claude Desktop, VS Code, and other MCP-compatible clients. This server runs locally on your machine via the stdio transport.
MIT
Microsoft Teams is released under the MIT license. This is a permissive open-source license, meaning you can freely use, modify, and distribute the software.
Add new capabilities to Claude beyond text generation
Example
Access external data sources, execute code, interact with tools and services
Transform Claude from chatbot to action-taking agent
Provide Claude with access to relevant context and data
Example
Load project documentation, access knowledge bases, query databases
Get more accurate, context-aware responses
Automate multi-step workflows combining AI and external tools
Example
Research → Summarize → Create document → Send notification
Complete complex tasks end-to-end without manual steps
Share your MCP server with the developer community
We wired Microsoft Teams into a staging workspace; the listing’s GitHub and npm pointers saved time versus hunting across READMEs.
Microsoft Teams is a well-scoped MCP server in the explainx.ai directory — install snippets and categories matched our Claude Code setup.
We wired Microsoft Teams into a staging workspace; the listing’s GitHub and npm pointers saved time versus hunting across READMEs.
Strong directory entry: Microsoft Teams surfaces stars and publisher context so we could sanity-check maintenance before adopting.
Microsoft Teams is a well-scoped MCP server in the explainx.ai directory — install snippets and categories matched our Claude Code setup.
According to our notes, Microsoft Teams benefits from clear Model Context Protocol framing — fewer ambiguous “AI plugin” claims.
Microsoft Teams has been reliable for tool-calling workflows; the MCP profile page is a good permalink for internal docs.
Microsoft Teams is among the better-indexed MCP projects we tried; the explainx.ai summary tracks the official description.
I recommend Microsoft Teams for teams standardizing on MCP; the explainx.ai page compares cleanly with sibling servers.
Strong directory entry: Microsoft Teams surfaces stars and publisher context so we could sanity-check maintenance before adopting.
showing 1-10 of 31
A Model Context Protocol (MCP) server that provides seamless integration with Microsoft Graph APIs, enabling AI assistants to interact with Microsoft Teams, users, and organizational data.
<a href="https://glama.ai/mcp/servers/@floriscornel/teams-mcp"> <img width="380" height="200" src="https://glama.ai/mcp/servers/@floriscornel/teams-mcp/badge" alt="Teams MCP server" /> </a>To use this MCP server in Cursor/Claude/VS Code, add the following configuration:
{
"mcpServers": {
"teams-mcp": {
"command": "npx",
"args": ["-y", "@floriscornel/teams-mcp@latest"]
}
}
}
Teams Management
Channel Operations
Team Members
The following tools now support rich message formatting in Teams channels and chats:
send_channel_messagesend_chat_messagereply_to_channel_messageupdate_channel_messageupdate_chat_messageYou can specify the format parameter to control the message formatting:
text (default): Plain textmarkdown: Markdown formatting (bold, italic, lists, links, code, etc.) - converted to sanitized HTMLWhen format is set to markdown, the message content is converted to HTML using a secure markdown parser and sanitized to remove potentially dangerous content before being sent to Teams.
If format is not specified, the message will be sent as plain text.
{
"teamId": "...",
"channelId": "...",
"message": "**Bold text** and _italic text_
- List item 1
- List item 2
[Link](https://example.com)",
"format": "markdown"
}
{
"chatId": "...",
"message": "Simple plain text message",
"format": "text"
}
**text**), italic (_text_), strikethrough (~~text~~)[text](url)- item) and numbered (1. item)`code` and blocks code # H1 through ###### H6<br> tags> quoted textMessages retrieved from the Microsoft Graph API are returned as raw HTML containing Teams-specific tags. To make this content more consumable by AI assistants, the following tools support automatic HTML-to-Markdown conversion:
get_chat_messagesget_channel_messagesget_channel_message_repliessearch_messagesget_my_mentionsUse the contentFormat parameter to control how message content is returned:
markdown (default): Converts Teams HTML to clean Markdown, optimized for LLM consumptionraw: Returns the original HTML from the Microsoft Graph API| HTML Element | Markdown Output |
|---|---|
<at id="0">Name</at> (Teams mention) | @Name (multi-word names merged using mentions metadata) |
<strong>text</strong> | **text** |
<em>text</em> | *text* |
<code>text</code> | `text` |
<a href="url">text</a> | [text](url) |
<ul><li>item</li></ul> | - item |
<table>...</table> | GFM Markdown table |
<attachment id="..."> | {attachment:id} |
<systemEventMessage/> | (removed) |
<hr> | --- |
, &, etc. | Decoded to plain characters |
Messages that contain file attachments or inline images include an attachments array in the response with metadata for each attachment (id, name, contentType, contentUrl, thumbnailUrl). The inline {attachment:id} markers in the markdown content correlate with entries in this array, allowing consumers to identify and download attachments via download_message_hosted_content or download_chat_hosted_content.
{
"chatId": "19:meeting_...",
"limit": 10,
"contentFormat": "markdown"
}
To get the original HTML (previous default behavior):
{
"chatId": "19:meeting_...",
"limit": 10,
"contentFormat": "raw"
}
# Install dependencies
npm install
# Build the project
npm run build
# Set up authentication
npm run auth
Full mode (default):
User.Read - Read user profileUser.ReadBasic.All - Read basic user infoTeam.ReadBasic.All - Read team informationChannel.ReadBasic.All - Read channel informationChannelMessage.Read.All - Read channel messagesChannelMessage.Send - Send channel messages and repliesChannelMessage.ReadWrite - Edit and delete channel messagesChat.Read - Read chat messages (included via read-only scopes)Chat.ReadWrite - Create and manage chats, send/edit/delete chat messages (supersedes Chat.Read)TeamMember.Read.All - Read team membersFiles.ReadWrite.All - Required for file uploads to channels and chatsRead-only mode (TEAMS_MCP_READ_ONLY=true) — only these scopes are requested:
User.ReadUser.ReadBasic.AllTeam.ReadBasic.AllChannel.ReadBasic.AllChannelMessage.Read.AllTeamMember.Read.AllChat.Read# Development mode with hot reload
npm run dev
# Production mode
npm run build && node dist/index.js
# Start in read-only mode (disables all write tools)
TEAMS_MCP_READ_ONLY=true node dist/index.js
The server supports a read-only mode that disables all write operations (sending messages, creating chats, uploading files, editing/deleting messages) and requests only read-permission scopes from Microsoft Graph.
Enable read-only mode using either:
TEAMS_MCP_READ_ONLY=true--read-onlyAuthenticate with reduced scopes: `
Prerequisites
Time Estimate
15-60 minutes depending on server complexity
Steps
Troubleshooting
✓ Do
✗ Don't
💡 Pro Tips
Architecture
Model Context Protocol standardizes how AI hosts (Claude, Cursor) communicate with external tools and data sources through server implementations.
Protocols
Compatibility
✓ Use when
Use when you need Claude to access external data, execute actions, or integrate with tools. Best for extending AI capabilities beyond conversation.
✗ Avoid when
Avoid when native integrations exist (use official APIs directly), for real-time critical systems, or when security/compliance requires zero external dependencies.