Microsoft 365 MCP
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
microsoft-365-mcp (+ Teams & SharePoint)
This is a modified copy of adelaidasofia/microsoft-365-mcp by Adelaida Diaz-Roa, MIT-licensed (see LICENSE). It adds opt-in Microsoft Teams and read-only SharePoint tools and removes the install ping. It is not affiliated with or endorsed by the original author. Issues with this copy go here, not upstream.
Already using the original? This copy is a drop-in replacement (same folder name, same keychain entry, your login keeps working):
git -C ~/microsoft-365-mcp remote set-url origin https://github.com/alejandrod-24/m365-mcp-sb.git && git -C ~/microsoft-365-mcp pull --ff-only
Multi-account, token-efficient MCP for Outlook mail + Calendar + OneDrive via Microsoft Graph. The Microsoft sibling of google-workspace-mcp. Built because the official Claude Microsoft 365 connector is read-only and vendor-locked — this one is your own app, your own OAuth, read-write, and works from any MCP client.
Set it up by talking to Claude
Paste this repository's link into Claude Code and say you want to connect your email. Claude Code does the terminal steps, and anything that needs a web browser goes to Claude in Chrome. GUIDED-SETUP.md is the step-by-step version of that path, including the exact browser steps.
Related MCP server: ckm365
Why this exists
Multi-account: OAuth multiple Microsoft accounts (work + personal). Every tool takes an
accountemail.Token-efficient: Search/list returns compact shapes (
{id, from, subject, snippet, ...}for mail,{id, name, mime, modified, size, ...}for OneDrive). Bodies and file content are opt-in; Graph converts mail bodies to plain text server-side (Prefer: outlook.body-content-type="text").Keychain-backed: Tokens live in the OS keychain on macOS (file fallback on Windows/Linux — see SETUP.md). No tokens in any repo.
Own-OAuth: You (or your team) register a free Entra app; a corporate admin can allowlist a single Client ID. No third-party middleman touches mail.
Tools (v0.1, 35 tools)
Account management (4)
m365_account_add— browser OAuth flow (ormethod="device_code"for headless)m365_account_complete— finish a device-code sign-inm365_account_list— list authorized accounts + defaultm365_account_remove— remove local tokens (doesn't revoke Microsoft-side)
Outlook mail (11)
outlook_search— KQL search or folder listing. Compact response.outlook_read— read one message or the whole conversation. Plain-text body.outlook_send— send mail (supportsdry_run=True)outlook_draft— create a draftoutlook_reply— reply / reply-all (Graph preserves the thread server-side)outlook_folders_list— folders with unread/total countsoutlook_move— batch move to a folder (well-known names work:archive,deleteditems, ...)outlook_archive— batch archiveoutlook_mark_read— batch mark read/unreadoutlook_attachments_list— list a message's attachments (filename, mime type, size)outlook_attachment_save— download one attachment to a local file, path returned for direct reading
Calendar (7)
mscal_list_calendars— list all calendarsmscal_list_events— list events, recurrences expanded (compact by default,verbose=Truefor full)mscal_create_event— create event, optional Teams meeting linkmscal_update_event— partial-update fieldsmscal_delete_event— delete/cancelmscal_freebusy— busy windows for one or more people (getSchedule)mscal_respond— accept/decline/tentative
OneDrive (13)
onedrive_search— search filenames + content. Metadata-only response.onedrive_read_file— metadata by default;include_content=Truefor bodyonedrive_list_folder— direct children ('root'for OneDrive root)onedrive_create_folder— create a folder (conflicts auto-rename)onedrive_upload— upload a local file; >4 MB goes through a chunked sessiononedrive_move— change parent folderonedrive_rename— renameonedrive_delete— recycle bin (recoverable), supportsdry_run=Trueonedrive_share— grant a person read/write access by emailonedrive_share_link— create a view/edit sharing linkonedrive_permission_list— who has accessonedrive_permission_update— change a grantee's roleonedrive_permission_delete— revoke access
Outlook uses folders + categories rather than Gmail labels; folder tools cover the label workflows.
Teams (opt-in, 6 + 1 tools) — M365_ENABLE_TEAMS=1
teams_list_chats— 1:1, group and meeting chats, most recent first, with membersteams_read_chat— latest messages of a chat as plain textteams_send_chat_message— send in a chat (dry_run=Truepreviews)teams_list_teams— teams you belong toteams_list_channels— channels of a teamteams_send_channel_message— post in a channel or reply to a post (dry_run)teams_read_channel— read channel posts and threads. Extra flagM365_ENABLE_TEAMS_CHANNEL_READ=1: it needsChannelMessage.Read.All, which only a tenant admin can consent.
SharePoint (opt-in, read-only, 8 tools) — M365_ENABLE_SHAREPOINT=1
sharepoint_search_sites/sharepoint_get_site(paste a browser URL)sharepoint_list_drives— document libraries of a sitesharepoint_list_folder/sharepoint_search_files/sharepoint_read_filesharepoint_list_lists/sharepoint_list_items— SharePoint lists and their rows
Both families are off by default so a tenant that blocks their permissions
never breaks the Outlook/Calendar/OneDrive login. After turning a flag on, run
m365_account_add again so the token picks up the new scopes. Teams and
SharePoint exist only on work/school accounts.
Install
Fastest path — one script, no manual wiring:
git clone https://github.com/alejandrod-24/m365-mcp-sb.git microsoft-365-mcp
bash microsoft-365-mcp/install.shinstall.sh creates an isolated venv, installs dependencies, takes your
Entra Application (client) ID (either interactively or via M365_CLIENT_ID
in the environment), and registers the server with Claude Code. Safe to
re-run. Then follow SETUP.md for the Entra app (2 minutes
with a shared team app, ~15 minutes solo) if you don't have a Client ID yet,
and OAuth your accounts.
git clone https://github.com/alejandrod-24/m365-mcp-sb.git microsoft-365-mcp
cd microsoft-365-mcp
pip install -e .Register in Claude Code — project scope (.mcp.json at your project root):
{
"mcpServers": {
"microsoft-365": {
"type": "stdio",
"command": "python3",
"args": ["/absolute/path/to/microsoft-365-mcp/server.py"]
}
}
}or user scope:
claude mcp add -s user microsoft-365 python3 /absolute/path/to/microsoft-365-mcp/server.pyConfig
Env var | Purpose |
| Entra Application (client) ID (or use |
|
|
| Default account email (else first authorized) |
| Force file token storage (auto on Windows) |
|
|
|
|
|
|
|
|
Observability
Every tool call appends a JSONL record (execution_time_ms, summarized io,
token_usage, error_class) to ~/.claude/microsoft-365-mcp/audit.log.jsonl.
Destructive OneDrive ops also land in a plain audit log next to it. Payload
contents are NOT logged unless you opt in with M365_AUDIT_IO=1.
Telemetry
None. The upstream install ping was removed in this copy.
Tests
pip install -e ".[test]"
pytest tests/52 tests run against a fake Graph transport — no network, no real tokens.
License
MIT
Built by Adelaida Diaz-Roa. Full install or team version at diazroa.com.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Permissioned access to Outlook, OneDrive and Teams via the user's own Microsoft account
Manage Microsoft 365 email, calendar, contacts and inbox rules via the Graph API with OAuth 2.0.
Read email/chat conversations, messages, contacts and teams; draft, send and update threads.
Gmail, Outlook, Drive, OneDrive and calendars for AI agents. Many accounts, one endpoint, audit log.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceEnables multiple users to securely connect their own Microsoft 365 account and use natural language to manage Outlook mail, Teams, and SharePoint/OneDrive files through Microsoft Graph, with support for shared mailboxes and admin governance.MIT
- AlicenseNot gradedqualityBmaintenanceEnables secure, multi-tenant Microsoft 365 mail and calendar management through Microsoft Graph, with tiered permissions, draft-only compose flows, and support for Claude Code, pydantic-ai, and programmatic access.MIT
- AlicenseNot gradedqualityBmaintenanceEnables interacting with Microsoft 365 and Office services through the Microsoft Graph API, covering email, calendar, files, Teams, SharePoint, contacts, tasks, and related organizational resources with authentication, read-only, and tool-filtering options.88,164 npmMIT
- AlicenseNot gradedqualityBmaintenanceEnables authenticated interaction with Microsoft 365 and Office services through the Graph API, covering email, calendar, files, Teams, SharePoint, and more. Supports read-only mode, tool filtering, presets, and multiple cloud environments for safe, controlled access.88,164 npmMIT