Skip to main content
Glama

outlook-classic-windows-mcp

用于处理本地配置的经典版 Outlook for Windows 桌面配置文件的 MVP MCP 服务器。

此工具不使用 Microsoft Graph、Outlook 网页版、新版 Outlook for Windows 或需要管理员启用的云 API。它通过 Windows COM 自动化,针对运行 MCP 服务器的机器上可用的经典 Outlook 桌面应用/配置文件进行操作。如果你不想联系 IT 支持或征求管理员的批准,这会很有用。

注意:此 MCP 是针对我自己的工作流程和需求定制的。建议你 fork 并修改它——或让你的编码代理帮你完成——以将 MCP 塑造成适合你自己的 Outlook 设置和用例。

警告:Microsoft 365 用户的经典版 Outlook for Windows 至少支持到 2029 年。新版 Outlook 将逐渐成为默认或替代品。此 MCP 在短期/中期内仍然可行。从长远来看,请使用基于管理员支持的 API 的其他 MCP!参见 https://learn.microsoft.com/en-us/answers/questions/5554339/when-will-classic-outlook-end

要求

  • Windows

  • 已安装并配置经典版 Microsoft Outlook 桌面版

  • uv

Related MCP server: outlook-mcp

安装/运行

cd C:\Users\muhammad.menjeni\git\outlook-classic-windows-mcp
uv sync
uv run outlook-local-mcp

MCP 服务器使用 stdio 通信,因此应由 MCP 客户端启动。

Pi MCP 配置示例

在 Pi MCP 配置中添加一个类似如下的本地服务器条目,必要时调整路径:

{
  "mcpServers": {
    "outlook-local": {
      "command": "uv",
      "args": [
        "--directory",
        "C:\\Users\\muhammad.menjeni\\git\\outlook-classic-windows-mcp",
        "run",
        "outlook-local-mcp"
      ]
    }
  }
}

工具

search_email

按主题和/或正文搜索 Outlook 邮件。

参数:

  • query 字符串:要查找的不区分大小写的子字符串。

  • folder 字符串:要搜索的文件夹。默认值:Inbox。你可以使用类似 Inbox/Archive 或 Mailbox Name/Inbox 的路径。

  • search_scope:all、subject 或 body。默认值:all。

  • max_results:要返回的匹配项数量。默认值:10。

  • max_items:要检查的文件夹中最新的项目数。默认值:500。

  • include_body_preview:是否包含简短的正文预览。默认值:true。

list_mail_folders

列出可用的 Outlook 文件夹,以帮助选择文件夹路径。

create_leave_calendar_blocks

创建两个未发送的 Outlook 日历项目用于休假审批:

  1. 一个标记为外出(Out of Office)、无参与者的个人占位项目。

  2. 一个标记为空闲(Free)、包含指定参与者的通知会议。

不会发送任何内容。默认情况下,两个项目都会保存并在 Outlook 中打开,供手动检查和发送。

参数:

  • start_time 字符串:开始日期/时间,例如 2026-09-01 08:00。

  • end_time 字符串:结束日期/时间。对于全天事件,这被解释为排他性结束时间,例如从 2026-09-04 00:00 到 2026-09-05 00:00 的一天。

  • required_attendees 列表/字符串:额外的通知收件人。也可以使用可配置的默认值。

  • subject 字符串:默认来自配置,初始为 Amirul: On-Leave。

  • body 字符串:消息正文。

  • optional_attendees 列表/字符串:可选的通知收件人。

  • location 字符串。

  • display 布尔值:是否在 Outlook 中打开已保存的项目。默认值:true。

  • confirmed 布尔值:必须为 true 才能实际创建 Outlook 日历项目。未经确认,该工具仅返回提案。

get_leave_defaults

显示当前的休假默认值和配置路径。

set_leave_defaults

持久化休假默认值,如主题和通知收件人。写入配置前需要 confirmed=true。

infer_leave_recipients

对最近的本地 Outlook 电子邮件进行只读扫描,以推断休假通知的候选通讯组列表。返回候选对象和证据;不会写入配置或创建草稿。

resolve_recipients

使用 Outlook 收件人解析/通讯簿解析姓名、电子邮件或通讯组列表。

search_contacts

按姓名、电子邮件、公司、部门或职位搜索本地 Outlook 联系人文件夹。

备注/限制

  • 首次访问时,如果 Outlook 尚未运行,可能会启动它。

  • 你的组织可能会显示 Outlook 对象模型保护提示,或通过策略阻止自动化。

  • 此 MVP 通过扫描最近的文件夹项目进行搜索,这简单可靠,但对于非常大的文件夹,不如索引化的 Outlook 搜索快。

Available Tools

8 tools
create_leave_calendar_blocksA

Create two unsent Outlook calendar items for leave review.

Creates:

  1. A personal calendar blocker marked Out of Office with no attendees.

  2. A meeting notification marked Free with the supplied attendees.

Nothing is sent. Items are saved locally, and by default opened in Outlook for manual review and sending.

Inputs: end_time (required), start_time (required), body, all_day, +6 more. Returns: object

get_leave_defaultsA

Return configurable defaults used by create_leave_calendar_blocks.

Inputs: no named parameters. Returns: object

infer_leave_recipientsB

Infer candidate leave-notification recipients/DLs from recent local Outlook email.

This is read-only. It scans recent mail subjects/bodies/recipients for distribution lists and department/team signals, then returns candidates for user confirmation.

Inputs: folders, max_results, max_items_per_folder. Returns: object

list_mail_foldersA

List Outlook store/folder paths to help choose the folder for search_email.

Inputs: max_depth. Returns: object

resolve_recipientsB

Resolve names, emails, or distribution lists using Outlook's address book/GAL.

Inputs: recipients (required). Returns: object

search_contactsB

Search local Outlook contact folders by name, email, company, or job title.

Inputs: query (required), max_results, max_folders_depth. Returns: object

search_emailA

Search locally configured Outlook desktop email by subject and/or body.

This scans the newest max_items messages in folder and returns up to max_results matches. It uses the local Outlook profile via COM, not Microsoft Graph or Outlook Web APIs.

Inputs: query (required), folder, max_items, max_results, +2 more. Returns: object

set_leave_defaultsB

Persist leave-calendar defaults. Requires confirmed=true because this writes config.

Inputs: notification_attendees (required), subject, confirmed. Returns: object

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.8/5.0

    Scored across 8 tools

    Disambiguation4/5

    Tools are mostly distinct, but three recipient-related tools (resolve_recipients, search_contacts, infer_leave_recipients) could cause some confusion regarding when to use each. However, their descriptions clearly differentiate (address book resolution vs. contact folder search vs. historical email inference), and the other tools are unambiguous.

    Naming Consistency5/5

    All tool names follow a strict verb_noun snake_case pattern (e.g., get_leave_defaults, search_email, create_leave_calendar_blocks). The pattern is predictable and consistent across all 8 tools, making it easy for an agent to infer naming conventions for hypothetical tools.

    Tool Count5/5

    With 8 tools, the server is well-scoped for its domain of Outlook leave management and search. Each tool serves a distinct function in a cohesive workflow, and the count is within the ideal range without being overwhelming or sparse.

    Completeness4/5

    The tool surface covers the core leave workflow: configuration, calendar block creation, recipient inference/resolution, and search capabilities. Minor gaps exist—such as no update/delete for leave calendar blocks—but these are unsent drafts intended for manual review, so the current surface seems sufficient for the stated purpose.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      D
      maintenance
      Enables AI assistants to read, send, and manage Outlook mail locally on Windows via COM/MAPI, without cloud APIs.
      17
      1
      MIT
    • F
      license
      Not graded
      quality
      C
      maintenance
      Reads and searches your local Microsoft Outlook desktop mailbox via COM, supporting folder listing, message/thread retrieval, attachment saving, bulk export, and draft creation without sending, requiring no OAuth or admin consent.
      -