Mail.app

io.github.p-l-ta由 GitHub 账号 p-l-ta 发布v1.3.5更新于 Oct 24, 2026

Search, read, send, and manage email via macOS Mail.app across all configured accounts.

已验证STDIO仅桌面效率与工作流沟通与协作

概览

AI 生成的概览

本地 MCP 服务器,让助手通过 macOS 邮件 App 在所有已配置账户中搜索、读取、发送和管理邮件。

可以做什么
  • 搜索与读取邮件:通过邮件 App 的信封索引按条件筛选邮件、读取正文、列出账户、邮箱、最近邮件和发件人。
  • 撰写与回复:从已配置账户发送新邮件,或按邮件 ID 回复已有邮件。
  • 整理邮件:设置已读与旗标状态、在邮箱间移动、移入废纸篓、批量标记已读或清空邮箱。
  • 邮箱与订阅管理:创建文件夹,并从邮件中提取退订链接。
适用场景
适合在已配置邮件 App 的 Mac 上使用,希望助手在不把邮件复制到别处的前提下,跨账户检索、整理、总结或起草并发送邮件。
运行要求
macOS 且已安装并配置邮件 App;Node.js 20+;支持 stdio 的 MCP 客户端(如 Claude Desktop)。宿主应用需授予完全磁盘访问权限和针对邮件的自动化权限,服务器进程会继承这些权限。
安装前请注意
可发送、回复、移动、删除邮件,甚至清空整个邮箱,存在误删或误发风险。它会读取本地邮件数据库并通过 AppleScript 操作邮件 App,邮件内容会作为工具结果传给 MCP 客户端。完全磁盘访问与自动化权限范围较大,建议限制宿主可调用的工具。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Mail.app,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

mail-mcp

MCP server that gives Claude (and other MCP hosts) full access to Mail.app on macOS — search, read, send, reply, flag, move, and more — across every account configured in Mail.app (iCloud, Exchange, IMAP, etc.).

Prerequisites

  • macOS (Mail.app required)
  • Node.js 20+
  • An MCP host: Claude Desktop, Amazon Quick, or any stdio MCP client

Installation

Claude Desktop — one-click install (recommended)

  1. Download mail-mcp.mcpb from the latest release
  2. Double-click the .mcpb file — Claude Desktop installs it automatically
  3. Grant the required macOS permissions (see below)

Manual / Amazon Quick / other hosts

bash
npx @p-l-ta/mail-mcp

Or install globally:

bash
npm install -g @p-l-ta/mail-mcpmail-mcp

Point your MCP host at the mail-mcp binary (stdio transport). Example config:

json
{  "mcpServers": {    "mail-app": {      "command": "npx",      "args": ["@p-l-ta/mail-mcp"]    }  }}

Required macOS permissions

Grant these to the application that runs the MCP host (Claude Desktop, Amazon Quick, etc.):

PermissionWhere to grant
Full Disk AccessSystem Settings → Privacy & Security → Full Disk Access
Automation → MailSystem Settings → Privacy & Security → Automation

The MCP server process inherits permissions from the host application that launches it.

Tools

ToolDescription
search_emailsSearch messages via the Envelope Index database with rich filters
read_emailRead the full body of a message by its RFC message-id
list_accounts_and_mailboxesList all configured accounts and mailboxes with unread counts
list_recentList recent messages in a specific mailbox
list_sendersGrouped summary of senders with message and unread counts
send_emailSend a new email from one of the configured accounts
reply_to_emailReply to an existing message by RFC message-id
set_message_flagsSet read and/or flagged status on a message
move_emailMove a message to a different mailbox
trash_emailMove a message to Deleted Messages
create_mailboxCreate a new mailbox/folder in an account
bulk_mark_readMark all messages in a mailbox and/or from a sender as read
get_unsubscribe_linkExtract unsubscribe URLs from a message's headers and body
empty_mailboxDelete every message in a mailbox at once (Junk, Trash, etc.)

How it works

  • Search & read — queries Mail's own Envelope Index SQLite database directly for fast, structured results across all accounts
  • Actions (send, reply, flag, move, trash) — driven by AppleScript automation against Mail.app, so they work even for accounts where messages aren't stored as local files

Development

bash
npm installnpm run dev          # tsx watch — live reloadnpm test             # vitest unit testsnpm run build        # compile TypeScript → dist/npm run mcpb         # build Claude Desktop extension → build/mail-mcp.mcpb

Interactive MCP testing:

bash
npm run buildnpx @modelcontextprotocol/inspector node dist/server.js

Privacy Policy

mail-mcp is a local MCP server that runs entirely on your Mac. It has no backend, no telemetry, and makes no network requests of its own.

What it accesses:

  • Mail.app's Envelope Index database (~/Library/Mail/) — read-only, used for search queries
  • Mail.app via AppleScript — to read message bodies, send mail, flag, move, and trash messages

What it does NOT do:

  • Collect, store, or transmit any data outside your Mac
  • Connect to any external server or API
  • Log message content anywhere

All email data stays on your device and is only passed to the MCP host (Claude Desktop or another client) as part of normal tool responses. You control exactly which tools Claude can invoke.

License

MIT

来源:README.md,提交 6357363

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

1
  1. v1.3.5最新Sep 16, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分