Holds sends to strangers as drafts
A send to anyone off send_allow is saved to Drafts for you to review.
$ chainmail send --account work --to (a printer off the list) ... held by policy, not sent: saved to Drafts $ echo $? 4
v0.2.0 released 16 November 2026, with calendars, rules and chainmail bootstrap.
chainmail is a Go daemon that holds your mail passwords and checks every send against a policy. Claude Code reaches it over MCP, and you reach it from the CLI.
Every chainmail call in these recordings went through the daemon and its audit log.
No MCP tool or CLI command can change the policy.
A send to anyone off send_allow is saved to Drafts for you to review.
$ chainmail send --account work --to (a printer off the list) ... held by policy, not sent: saved to Drafts $ echo $? 4
Subjects, senders and bodies arrive in an untrusted envelope, as data.
{
"subject": {
"untrusted": "Overdue: invoice 4471"
},
"from": { "untrusted": "Accounts Payable" }
}expunge and folder delete stay off, and unlisted, until the config allows them.
# config.toml policy.send_allow = ["*@example.org"] policy.max_recipients = 10 policy.allow_expunge = false policy.allow_folder_delete = false
An append-only log in state.db that never holds message content or secrets.
$ chainmail audit --since 5m --action send AT ACTION DECISION REASON 08:49:59 send allowed 08:49:46 send held HELD
The vault
The daemon keeps every password and token in an age-encrypted vault, and no call ever returns one.
Claude Code starts chainmail mcp, which holds no secrets and passes each call over a Unix socket to the daemon.
The daemon checks the policy, writes the audit row and talks IMAP and SMTP to your mail servers. The socket admits only the daemon's user and the chainmail-clients group.
Read the manualYes, to your own accounts and to the addresses and domains in send_allow. A send to anyone else, or to more than max_recipients (10 by default), is saved to Drafts for you to send. How held sends work
In an age-encrypted vault that only the daemon reads. No call returns a secret, and admin status lists secret names only.
An agent that can run sudo without a password can get around all of it, so run agents from an account that cannot. A dev daemon runs as you, so use it only for work on chainmail. trash, move and archive are not gated.
Gmail and Google Workspace over OAuth2, Gmail with an app password, iCloud, Hostinger, and any IMAP and SMTP server that takes a password. Set up each provider
Yes. chainmail mcp speaks MCP over stdio, and the manual shows the Codex config. An agent that runs shell commands can use the CLI, which prints JSON when piped.
Google Calendar on Gmail and Google Workspace accounts that log in with OAuth2, and CalDAV servers such as Mailwright. Calendars arrived in v0.2.0.
v0.2.0 runs on Linux and macOS. On NixOS, bootstrap writes Nix files for your configuration.
Homebrew installs chainmail with its shell completions and man page.
$ brew install yaklabco/tap/chainmail $ chainmail version
Bootstrap sets up the daemon as its own user, stores the account's password and tests the login. It asks for sudo once.
$ chainmail bootstrap [email protected] $ chainmail accounts test you
This registers the MCP server for every project.
$ claude mcp add --scope user chainmail \
-- "$(command -v chainmail)" mcp