Why a coding agent needs email
Coding agents hit email more often than you would think:
- Testing a sign-up flow. The app under development emails a confirmation link. The agent needs an address that receives it, and a way to wait for it.
- Signing up for a service. A new API, a staging dashboard, a package registry. Each sends a code.
- Checking the app's own mail. Does the password-reset email render, does the link work, is the from address right.
- Reporting back. A long job finishes overnight and the agent emails a summary.
Using your own address for these means you fetch every code. Using a throwaway means the account's later mail goes nowhere. An address the agent owns fixes both.
Claude Code
One command adds the hosted server:
claude mcp add --transport http pidgeon https://pidgeon.ai/api/mcp --scope user
--scope user makes it available in every project; --scope project writes it to .mcp.json to share with the repository. Then open /mcp, pick pidgeon and sign in in the browser. The consent screen asks what the agent may do, read, read and send, or full access, and which addresses it reaches. That choice becomes an API key held for Claude Code, listed under Developers → API keys → Connected apps, where Disconnect ends it.
For an agent with nobody there to sign in, such as one in CI, pass a key instead:
claude mcp add --transport http pidgeon https://pidgeon.ai/api/mcp \
--header "Authorization: Bearer $PIDGEON_API_KEY"
Or install the plugin, which adds the server and the Pidgeon skill together:
/plugin marketplace add pidgeon-ai/pidgeon-plugins
/plugin install pidgeon@pidgeon
Cursor
Add Pidgeon from its cursor.directory listing, or add the server by hand to ~/.cursor/mcp.json (or .cursor/mcp.json for one project):
{
"mcpServers": {
"pidgeon": {
"url": "https://pidgeon.ai/api/mcp"
}
}
}
Cursor signs you in on the first call. To use a key instead, add "headers": { "Authorization": "Bearer ${env:PIDGEON_API_KEY}" } beside the URL, and Cursor fills it from your environment.
Codex, VS Code and Gemini CLI take the same server; npx -y @pidgeon-ai/mcp init --client codex (or vscode, or gemini) writes it into that client's own config file.
Or one line, and let the agent do it
If you have no account yet, paste this into the agent:
Read pidgeon.ai/skill.md and get yourself an email address.
The agent signs itself up with two HTTP calls. The address is live at once and can receive; to send, it asks you for a six-digit code that arrives at your address. Then it stores the key and connects the MCP server.
What it looks like in use
Ask Claude Code to "test the sign-up flow on localhost:3000 and confirm the email arrives". With Pidgeon connected it will:
- call
create_addressand get an address such astest-7c1e@pidgeon.email; - fill in the form, with a browser tool or a request;
- call
await_messagewithhas_code: true, which returns when the email lands, with the code inextracted.codesand the confirmation link at the top ofextracted.links; - follow the link, or type the code, and report what the email said.
The email the agent reads is cleaned of hidden text first, and checked by Pidgeon Firewall, because the agent is about to act on text somebody else wrote. If you want the agent to write mail but not send it, choose read-and-draft at the consent screen: it writes drafts, and a person sends them.
Other options
Any MCP server that can send and receive email works the same way in both clients. Email MCP servers compared sets out what to check: whether it can wait for mail, whether replies stay in the thread, and what it does about injection. If you would rather the agent worked in your own Gmail, Google's official Gmail MCP server writes drafts for you to send; Pidgeon vs the Gmail API compares the two approaches.
Start
Sign up, or paste the line above. The Claude Code and Cursor pages have the same steps, and the MCP guide lists every tool.