proton-mcp-server
Provides read-only access to Proton Mail via MCP, enabling AI agents to list accounts/folders, search messages, and read emails using Proton Mail Bridge's local IMAP server.
README
Proton Mail MCP Server
Read-only access to Proton Mail for AI agents (such as Hermes) over the Model Context Protocol (stdio transport).
Mail is read from Proton Mail Bridge, which runs a local IMAP server. The MCP server wraps that IMAP server and exposes a small set of tools. Multiple Proton accounts are supported and selected by name on each tool call.
Read-only by design: listing folders/messages, searching, and reading a message. Sending or moving/deleting mail is intentionally out of scope.
How it works
+----------+ stdio/stdin+stdout +---------------------+ IMAP (local) +---------------------+
| Agent | <---------------------> | proton-mcp-server | <------------> | Proton Mail Bridge |
| (Hermes) | MCP (JSON-RPC) | (this package) | 127.0.0.1:1143 | (protonmail-bridge)|
+----------+ +---------------------+ +---------------------+
Proton Mail Bridge must be installed, signed in, and running. In the Bridge GUI, for each account enable the IMAP/SMTP client and copy the generated password (this is not your Proton account password).
Install
Requires Python 3.11+. Using uv (recommended):
git clone <this repo> && cd proton-mcp-server
uv sync # create venv + install dependencies
Or with pip into a venv of your choice: pip install .
The proton-mcp-server console script is provided.
Configure accounts
Create a config file listing each account (see config.example.toml):
mkdir -p "${XDG_CONFIG_HOME:-$HOME/.config}/proton-mcp"
cp config.example.toml "${XDG_CONFIG_HOME:-$HOME/.config}/proton-mcp/config.toml"
# then edit it with your bridge username + generated password
Config-file lookup order (first wins):
--config PATHCLI flagPROTON_MCP_CONFIGenvironment variable$XDG_CONFIG_HOME/proton-mcp/config.toml(default~/.config/proton-mcp/config.toml)
[[accounts]] fields:
| field | required | default | notes |
|---|---|---|---|
name |
yes | — | Unique label agents pass as the account argument. |
username |
yes | — | Your Proton address (the IMAP login name). |
password |
yes | — | Password generated by Proton Mail Bridge, not Proton. |
host |
no | 127.0.0.1 |
Bridge listens on localhost. |
port |
no | 1143 |
Bridge IMAP port. |
security |
no | starttls |
starttls (Bridge v3 default), ssl (TLS from start), plain. |
Tools
| tool | description |
|---|---|
list_accounts |
List configured account names. |
list_folders |
List mailboxes for an account (INBOX, Sent, …). |
list_messages |
List recent messages in a folder, newest first. |
search_messages |
Search a folder by subject/from/to/cc/body/text. |
get_message |
Fetch and render a full message by UID. |
Run proton-mcp-server --list-accounts to smoke-test the config (this does
not require Bridge to be reachable — it only parses the file).
Use with Hermes
Add the server to your Hermes MCP configuration (stdio server):
{
"mcpServers": {
"proton-mail": {
"command": "/abs/path/to/proton-mcp-server/.venv/bin/proton-mcp-server",
"env": { "PROTON_MCP_CONFIG": "/abs/path/to/proton-mcp/config.toml" }
}
}
}
(Or omit env if you use the default config path.) Then ask Hermes to read
your mail; it will discover the tools via MCP.
Develop / debug
uv sync
uv run proton-mcp-server --help
uv run proton-mcp-server --print-config-path
uv run proton-mcp-server --list-accounts
To inspect the protocol by hand, pipe a JSON-RPC initialize + tools/list
exchange into the running server over stdio.
Security notes
- Config holds bridge passwords; keep it readable only by you (
chmod 600).config.tomlis git-ignored by default. - The connection to Proton Mail Bridge is localhost only. The default
security = "starttls"upgrades to TLS via STARTTLS after connecting; the Bridge's local self-signed certificate is accepted with verification disabled (the connection never leaves localhost).security = "ssl"(TLS from connection start) andsecurity = "plain"(no encryption) are also available. The server never connects to a remote host with verification off — and all connection fields are configurable per account. - All operations are read-only (BODY.PEEK, no STORE/EXPUNGE).
License
MIT — see LICENSE.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。