原型 · 预览版:收录官方注册中心里的全部服务器,每 30 分钟同步一次。评价和账户功能将在后续阶段推出。
PopNx MCP为使用 AI 的人准备的 MCP 服务器 · 用大白话讲清楚

MSGraph MCP

作者:timfurlong版本 0.5.1i★ –i在你的电脑上运行
注册名称io.github.timfurlong/msgraph-mcp

安装

概览

作者提供的说明(英文原文)

MCP server for Microsoft Graph: Outlook mail and calendar, plus read-only Microsoft Teams

PopNx MCP 的三大支柱

这三项永远不会合并成一个分数:意见、测量和人气是不同的东西。

它能帮你做什么

我们还没有为它写通俗的介绍。下面是我们从注册中心读取到的事实。

  • 连接方式: 在你的电脑上运行
  • 传输方式: stdio
  • 分类: 聊天与邮件
  • 你需要填写:MSGRAPH_MCP_CLIENT_ID, MSGRAPH_MCP_TENANT_ID

安装

选择你使用的 AI 应用,然后复制设置。

安装之前

  • 基础检查:1 项中通过 1 项
  • 在你的电脑上运行,拥有你的用户账户的权限(文件、网络、应用)。
  • 需要你自己填写: MSGRAPH_MCP_CLIENT_ID, MSGRAPH_MCP_TENANT_ID, MSGRAPH_MCP_TOKEN_CACHE_PATH

你需要

  • PyPI已安装 Python 的 uv(用于 uvx 命令)

你用的是哪个应用?

在上方选择你的应用。我们会记住它,下次按钮会显示“安装到 …”。

打开 Claude Desktop → Settings → Developer → Edit Config,把下面的内容粘贴到 claude_desktop_config.json

{
  "mcpServers": {
    "msgraph": {
      "command": "uvx",
      "args": [
        "msgraph-mcp-server"
      ],
      "env": {
        "MSGRAPH_MCP_CLIENT_ID": "your-value",
        "MSGRAPH_MCP_TENANT_ID": "your-value",
        "MSGRAPH_MCP_TOKEN_CACHE_PATH": "your-value"
      }
    }
  }
}

在终端中运行这条命令

claude mcp add msgraph --env MSGRAPH_MCP_CLIENT_ID=your-value --env MSGRAPH_MCP_TENANT_ID=your-value --env MSGRAPH_MCP_TOKEN_CACHE_PATH=your-value -- uvx msgraph-mcp-server

运行前请先填写空着的值。

在 Cursor 中打开

或者自己复制设置

粘贴到项目中的 .cursor/mcp.json,或 ~/.cursor/mcp.json

{
  "mcpServers": {
    "msgraph": {
      "command": "uvx",
      "args": [
        "msgraph-mcp-server"
      ],
      "env": {
        "MSGRAPH_MCP_CLIENT_ID": "your-value",
        "MSGRAPH_MCP_TENANT_ID": "your-value",
        "MSGRAPH_MCP_TOKEN_CACHE_PATH": "your-value"
      }
    }
  }
}

浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。

在 VS Code 中打开

或者自己复制设置

粘贴到项目中的 .vscode/mcp.json

{
  "servers": {
    "msgraph": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "msgraph-mcp-server"
      ],
      "env": {
        "MSGRAPH_MCP_CLIENT_ID": "your-value",
        "MSGRAPH_MCP_TENANT_ID": "your-value",
        "MSGRAPH_MCP_TOKEN_CACHE_PATH": "your-value"
      }
    }
  }
}

浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。

这个服务器在你的电脑上运行,而 ChatGPT 只能连接互联网上的服务器。请选择其他应用。

你的选择通过 Cookie 保存在这台设备上,无需账户。

需要你填写的值

  • MSGRAPH_MCP_CLIENT_ID 必填 env
    Client ID of your Entra (Azure AD) app registration
  • MSGRAPH_MCP_TENANT_ID 必填 env
    Entra tenant ID (or 'common' / 'organizations' / 'consumers')
  • MSGRAPH_MCP_TOKEN_CACHE_PATH env
    Override the token cache location (default ~/.msgraph-mcp/token_cache.bin)

这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。

它能做什么

它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。

基础检查i

我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月6日

  • ✓ 通过

    作者与仓库一致

    注册名称已通过 GitHub 账户 timfurlong 验证,该账户拥有此仓库

  • … 尚未检查

    仍在维护

    我们还没有从 GitHub 读取这个仓库

  • … 尚未检查

    有许可证

    我们还没有从 GitHub 读取这个仓库

  • – 不适用

    端点有响应

    它在你的电脑上运行,没有互联网端点

  • – 不适用

    使用 OAuth 登录

    在你的电脑上运行,改用本地设置

  • … 尚未检查

    工具描述中没有隐藏指令

    它在你的电脑上运行;我们只能读取互联网端点的工具列表

与“聊天与邮件”中的其他服务器比较i

  • 星标数多于此分类中其他 1763 个服务器的 0%
  • 发布到注册中心的时间比此分类中其他 1763 个服务器的 35% 更新
  • 基础检查结果等于或优于此分类中其他 1763 个服务器的 100%

与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。

常见问题

MSGraph MCP 安全吗?

它在 1 项适用的基础检查中通过了 1 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。

它需要哪些密钥或代码?

你需要填写:MSGRAPH_MCP_CLIENT_ID, MSGRAPH_MCP_TENANT_ID

它在我的电脑上运行还是在云端?

它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。

它还在维护吗?

GitHub 仓库最后更新于–,最新版本(0.5.1)于2个月前进入注册中心。

哪些应用可以使用它?

支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Python (uv)。

有什么可以替代它?

同一分类中有:Vexa, emailmd, MCP WhatsApp Cloud

替代选择

同一分类中其他作者的服务器,按星标数排序。

如何看卡片:★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i

Vexa

作者:Vexa-ai

Meeting bot and transcripts for Google Meet, Teams and Zoom. Live or after, speakers labelled.

在云端运行★ 2,949Apache-2.02个月前更新
安装

emailmd

作者:anypost

Render markdown into email-safe HTML, lint drafts for deliverability problems, and preview emails.

电脑或云端★ 1,385MIT30天前更新
安装

MCP WhatsApp Cloud

作者:codespar

MCP server for WhatsApp Cloud API (Meta) — messages, media, and templates via Graph API

在你的电脑上运行★ 277MIT5个月前更新
安装

作者的 README

打开 README

按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。

MSGraph MCP

A Model Context Protocol (MCP) server for Microsoft Graph. It exposes Microsoft Outlook mail and calendar, plus read-only Microsoft Teams message history, to AI agents via the Microsoft Graph SDK. It acts as the signed-in user, using delegated permissions and MSAL device code flow, so it can only reach what that user can reach.

Install

You need Python ≥ 3.11 and an Entra (Azure AD) app registration. The app registration takes about ten minutes and may need an administrator, so do that first: see the Entra setup section below.

uv tool install msgraph-mcp-server   # or: pip install msgraph-mcp-server

The package is msgraph-mcp-server. It installs three commands: msgraph-mcp and its alias msgraph-mcp-server, which both start the stdio server, plus msgraph-mcp-login for the one-time sign-in.

Setup

1. Set your Entra app credentials.

export MSGRAPH_MCP_CLIENT_ID=<your app's client ID>

export MSGRAPH_MCP_TENANT_ID= # or: common / organizations / consumers

2. Sign in once. This prints a URL and a code; visit the URL and enter the code. No client secret is involved or stored.

msgraph-mcp-login

running via uvx instead of installing: uvx --from msgraph-mcp-server msgraph-mcp-login

A token cache is written to ~/.msgraph-mcp/token_cache.bin.

3. Wire the server into your MCP host.

Claude Code:

claude mcp add msgraph \

--env MSGRAPH_MCP_CLIENT_ID=$MSGRAPH_MCP_CLIENT_ID \ --env MSGRAPH_MCP_TENANT_ID=$MSGRAPH_MCP_TENANT_ID \ -- msgraph-mcp

Any other host, over stdio:

{

"mcpServers": { "msgraph": { "command": "msgraph-mcp", "args": [], "env": { "MSGRAPH_MCP_CLIENT_ID": " ", "MSGRAPH_MCP_TENANT_ID": " " } } } }

To run without installing, use "command": "uvx" with "args": ["msgraph-mcp-server"]. Note that uvx does not put msgraph-mcp-login on your PATH, so sign in with the uvx --from form shown in step 2.

MSGRAPH_MCP_TOKEN_CACHE_PATH optionally overrides the cache location. All three variables can also come from a .env file in the working directory; the process environment wins over it.

Entra setup

The app registration requires:

  • Account type: single tenant (multi-tenant works too; set MSGRAPH_MCP_TENANT_ID to common, organizations, or consumers)
  • Redirect URI (public client): https://login.microsoftonline.com/common/oauth2/nativeclient
  • Allow public client flows: Yes, under Authentication → Advanced settings. Device code flow fails without it.
  • Delegated permissions (Microsoft Graph):
  • Mail: Mail.ReadWrite, Mail.ReadWrite.Shared, Mail.Send
  • Rules: MailboxSettings.ReadWrite (Graph requires this for the messageRules endpoints)
  • Calendar: Calendars.ReadWrite, Calendars.ReadWrite.Shared
  • Identity: User.Read
  • Teams: Chat.Read, Team.ReadBasic.All, Channel.ReadBasic.All, ChannelMessage.Read.All

ChannelMessage.Read.All always needs tenant admin consent, and the *.Shared permissions may need it depending on your tenant.

The scope list is all-or-nothing. Sign-in requests every scope at once, so without admin consent for ChannelMessage.Read.All the login fails outright and mail and calendar are unavailable too. For the same reason, adding scopes later means re-running msgraph-mcp-login; until you do, *every* tool fails with NotAuthenticatedError, not just the ones needing the new scope.

Tools

GroupTools
Utilwhoami
Mail — readlist_messages, search_messages, get_message, list_attachments, download_attachment
Mail — writesend_message, create_draft, reply_message, reply_all_message, forward_message, update_message, delete_message
Mail — folderslist_folders, create_folder, update_folder, delete_folder, move_message
Mail — actionsarchive_message, mark_read, mark_unread, flag_message, unflag_message
Mail — batchbatch_archive_messages, batch_move_messages, batch_mark_read, batch_mark_unread, batch_flag_messages, batch_unflag_messages
Mail — ruleslist_rules, get_rule, create_rule, update_rule, delete_rule
Calendarlist_calendars, list_events, get_event, create_event, update_event, delete_event, cancel_event, respond_to_event, find_meeting_times
Teams (read)list_chats, list_chat_messages, list_joined_teams, list_channels, list_channel_messages, list_message_replies, download_hosted_content

Behavior shared across tools:

  • Trimmed responses. Results are reshaped for agents, and message and event bodies are replaced by a short snippet. Pass include_body=true to get_message, list_chat_messages, list_channel_messages, or list_message_replies for the full body, which for Teams is also what surfaces Adaptive Card content. Pass include_raw=true to any tool returning a Graph object to get the full payload alongside the trimmed one; the batch_* tools return per-message status only and do not accept it.
  • Other mailboxes. Every mail and calendar tool takes an optional mailbox (email or user ID) to target a shared or delegated mailbox. Omit it for your own. Teams tools are read-only, cover only your own chats, and take no mailbox.
  • Pagination. List and search tools take limit (1-100, default 25) and page_token, except list_channel_messages and list_message_replies, which Graph caps at 50. list_folders, list_rules, list_attachments, and list_calendars return the whole collection and take neither. On list_joined_teams and list_channels, limit is applied after fetching because Graph rejects $top there, so it saves tokens rather than round-trips.
  • Batch actions. The batch_* tools apply one action to up to 1000 messages via Graph's $batch endpoint, returning a per-message result plus a {total, succeeded, failed} summary.
  • Downloads. download_attachment and download_hosted_content return images as native MCP image blocks the agent can view. Pass save_path (a file, or an existing directory) to write bytes to disk and get back a path instead.
  • Finding mail. list_messages defaults to the inbox; pass folder_id for another folder, unread_only=true, or a raw OData filter for predicates KQL cannot express. search_messages passes your query to Graph's $search as KQL.

Outgoing attachments are capped at 3 MB total per message; chunked upload is not supported. SharePoint-backed Teams file attachments cannot be downloaded, only inline hosted content.

Security

The token cache holds your refresh token, which can mint access tokens for your mail, calendar, and Teams data. Treat the file as a credential. It lives at ~/.msgraph-mcp/token_cache.bin with mode 0600 inside a 0700 directory.

To revoke access, or to switch accounts, delete the cache and sign in again:

rm -f ~/.msgraph-mcp/token_cache.bin ~/.outlook-mcp/token_cache.bin

The second path matters if you ever ran this server under its former name outlook-mcp: that cache is still used as a fallback when the current one is absent, so deleting only the first file leaves a working refresh token on disk. To revoke fully, also remove the app at https://account.microsoft.com or in your organization's identity portal.

Troubleshooting

  • `NotAuthenticatedError: Not authenticated` — run msgraph-mcp-login. If it recurs immediately, a requested scope has not been consented yet; see the note under Entra setup.
  • `ConfigError: Missing required env var` — set it in your shell, in a .env in the working directory, or in your MCP host's env config.
  • `Graph API 403: ErrorAccessDenied` — the Entra app is missing a delegated permission, or it needs admin consent. Check the list above, then re-consent and sign in again.
  • `Graph API 400: BadRequest — Syntax error` from search_messages — the query goes to Graph's $search as KQL. Quote literal phrases ("weekly report") or use fielded forms (from:alice). For predicates KQL cannot express, use list_messages with filter=.
  • The host starts the server but lists no tools — confirm it launches msgraph-mcp (or uvx) over stdio and can find that binary on its PATH.

Development

See CONTRIBUTING.md.

问 PopNx