Token导航 LogoToken导航TokenDH.com
Protonmail MCP Server logo
AI代理未说明官方来源来源级核验

Protonmail MCP Server

MCP Server

ProtonMail MCP Server 是一个非官方的IMAP支持的MCP服务器,为ProtonMail Bridge提供邮箱操作功能,使AI助手可以通过本地Bridge连接列出、搜索和检索邮件。

工具数

12

提示词数

0

GitHub Stars

1

资源数

0
邮件服务RustToken认证

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

TensorTemplar

提供方

TensorTemplar

最后核验

2026/5/17 20:21

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

详细介绍

ProtonMail MCP服务器

ProtonMail Bridge的非官方IMAP支持的MCP(模型上下文协议)服务器。将邮箱操作公开为MCP工具,以便AI助手可以通过本地网桥连接列出、搜索和检索邮件。

新闻

v2026.2.2-重大变更

search_emails 命名至 get_inbox_items -老人 search_emails 该工具(列出了带有可选日期过滤的电子邮件)已重命名为 get_inbox_items 以更好地反映其目的。

search_emails 使用关键字搜索 -一个新的 search_emails 该工具现在提供实际的基于关键字的搜索和字段选择:

{
  "mailbox": "INBOX",
  "query": "meeting notes",
  "fields": ["subject", "from"],
  "since_date": "2025-01-01T00:00:00Z",
  "limit": 30
}
参数必填说明
query搜索关键字
fields要搜索的字段: text (任何地方), subject, from, to, body.默认为 text.
since_dateISO 8601日期过滤器
mailbox默认为 INBOX
limit默认为30

快速入门

安装

预构建二进制文件(推荐):

Linux:

curl -LO https://github.com/TensorTemplar/protonmail-mcp-server/releases/latest/download/protonmail-mcp-server-x86_64-unknown-linux-gnu.tar.gz
tar xzf protonmail-mcp-server-x86_64-unknown-linux-gnu.tar.gz
chmod +x protonmail-mcp-server
sudo mv protonmail-mcp-server /usr/local/bin/

macOS(苹果硅):

curl -LO https://github.com/TensorTemplar/protonmail-mcp-server/releases/latest/download/protonmail-mcp-server-aarch64-apple-darwin.tar.gz
tar xzf protonmail-mcp-server-aarch64-apple-darwin.tar.gz
chmod +x protonmail-mcp-server
sudo mv protonmail-mcp-server /usr/local/bin/

macOS(英特尔):

curl -LO https://github.com/TensorTemplar/protonmail-mcp-server/releases/latest/download/protonmail-mcp-server-x86_64-apple-darwin.tar.gz
tar xzf protonmail-mcp-server-x86_64-apple-darwin.tar.gz
chmod +x protonmail-mcp-server
sudo mv protonmail-mcp-server /usr/local/bin/

Windows(PowerShell):

Invoke-WebRequest -Uri "https://github.com/TensorTemplar/protonmail-mcp-server/releases/latest/download/protonmail-mcp-server.exe-x86_64-pc-windows-msvc.zip" -OutFile "protonmail-mcp-server.zip"
Expand-Archive protonmail-mcp-server.zip -DestinationPath .

通过货物:

# From crates.io
cargo install protonmail-mcp-server --features http

# Or from source
git clone https://github.com/TensorTemplar/protonmail-mcp-server
cd protonmail-mcp-server
cargo install --path . --features http

验证下载(可选)

所有发布的二进制文件都包含用签名的SHA256校验和 Sigstore.

校验和验证:

# Download the checksums file
curl -LO https://github.com/TensorTemplar/protonmail-mcp-server/releases/latest/download/SHA256SUMS.txt

# Verify your downloaded binary (run in same directory as the .tar.gz/.zip)
sha256sum -c SHA256SUMS.txt --ignore-missing
# Expected output: protonmail-mcp-server-x86_64-unknown-linux-gnu.tar.gz: OK

签名验证(需要 联署):

# Download the signature bundle
curl -LO https://github.com/TensorTemplar/protonmail-mcp-server/releases/latest/download/SHA256SUMS.txt.bundle

# Verify the checksums file was signed by this repo's GitHub Actions
cosign verify-blob \
  --certificate-identity-regexp "github.com/TensorTemplar/protonmail-mcp-server" \
  --certificate-oidc-issuer https://token.actions.githubusercontent.com \
  --bundle SHA256SUMS.txt.bundle \
  SHA256SUMS.txt
# Expected output: Verified OK

配置并运行

# Set environment variables
export IMAP_HOST=127.0.0.1
export IMAP_PORT=1143
export IMAP_USERNAME=your@email.com
export IMAP_PASSWORD=your-bridge-password
export MCP_TRANSPORT=http
export MCP_AUTH_TOKEN=your-secret-token

# Run
protonmail-mcp-server

或者复制并编辑示例env文件:

cp .env.example .env
# Edit .env with your settings
protonmail-mcp-server

HTTP传输部署

建筑

┌─────────────┐     HTTPS/SSE      ┌──────────────────┐     IMAP
│   Agent 1   │◄──────────────────►│                  │◄──────────►┌────────────────┐
├─────────────┤                    │   MCP Server     │            │ ProtonMail     │
│   Agent 2   │◄──────────────────►│   (HTTP+SSE)     │◄──────────►│ Bridge         │
├─────────────┤                    │                  │            │                │
│   Agent N   │◄──────────────────►│ Per-session IMAP │◄──────────►│ localhost:1143 │
└─────────────┘                    └──────────────────┘            └────────────────┘
  • 每个MCP会话都有自己的IMAP连接
  • 需要承载令牌身份验证
  • SSE(服务器发送事件)用于流式响应

配置

变量默认值描述
MCP_TRANSPORTstdio运输方式: stdiohttp
MCP_HTTP_BIND127.0.0.1:8080HTTP服务器绑定地址
MCP_AUTH_TOKEN(http需要)身份验证的承载令牌
MCP_SSE_KEEPALIVEtrue启用SSE保持活动ping(见下面的注释)
注: 如果使用Python MCP SDK\ 旧的SDK无法处理作为保活ping发送的空SSE数据字段。 请参阅: python sdk#1672

正在运行HTTP服务器

# Via environment
MCP_TRANSPORT=http MCP_AUTH_TOKEN=secret123 ./target/release/protonmail-mcp-server

# Via CLI override
./target/release/protonmail-mcp-server --transport http --bind 0.0.0.0:8080

客户端使用情况

# Initialize session
curl -X POST http://localhost:8080/mcp \
  -H "Authorization: Bearer secret123" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"my-agent","version":"1.0"}}}'

安全注意事项

  1. 网络绑定:默认值 127.0.0.1 (仅限本地主机)。使用 0.0.0.0 用于远程访问。
  2. 认证: MCP_AUTH_TOKEN 对于HTTP模式是必需的。
  3. 传输层安全:对于生产环境,使用HTTPS在反向代理(nginx、Caddy)后面部署。

可用的MCP工具

工具说明注释
list_mailboxes列出可用邮箱只读
get_inbox_items从具有可选日期筛选功能的邮箱获取电子邮件只读
search_emails在指定字段中按关键字搜索电子邮件只读
get_email按ID获取完整的电子邮件内容只读
get_current_date获取当前UTC时间戳只读
list_tags列出邮箱的可用标志只读
get_email_tags获取特定电子邮件上的标志只读
apply_tag将标记应用于电子邮件幂等
remove_tag从电子邮件中删除标志破坏性
move_email将电子邮件移动到另一个文件夹破坏性
move_emails将多封电子邮件移动到另一个文件夹破坏性
get_attachment下载附件(文件或base64)破坏性,开放世界

赞助商

如果您觉得这个项目有用,请考虑支持我们:

![Sponsor $10](https://buy.stripe.com/28o4gL5Qu9URaFaeUU) ![Sponsor $6/month](https://buy.stripe.com/aEUaF992G5EBaFa8wx)

请在SPONSORS.md中列出的付款单中注明您的姓名和项目。

目录标签

目录标签

邮件服务RustToken认证本地部署IMAPMCP协议AI助手本地连接

接入字段

传输方式(transport,传输协议)

未说明

鉴权方式(authType,认证方式)

token

工具数量(toolCount,工具数)

12

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

未说明token部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

仍需确认:installCommand

来源信息

继续浏览同类 MCP