mcp · agenticmail — Claude Code MCP server: real email and SMS for agents
The AgenticMail MCP server gives an AI agent a real inbox: send mail and texts, read replies, grab verification codes, manage contacts and hand tasks to other agents.
claude mcp add --env AGENTICMAIL_API_KEY=<AGENTICMAIL_API_KEY> --env AGENTICMAIL_MASTER_KEY=<AGENTICMAIL_MASTER_KEY> --env AGENTICMAIL_API_URL=<AGENTICMAIL_API_URL> --transport stdio mcp -- npx -y @agenticmail/mcpWhat mcp does
It runs as a subprocess the client talks to over standard input and output, so no network ports are opened. Each tool call becomes a request to the AgenticMail API, and the answer comes back as text the model can read. The package advertises 100 tools covering email, SMS and agent management: send, reply, forward, templates, drafts, contacts, scheduled sends.
Multi-agent work has its own tier. call_agent takes an outputSchema and validates submit_result against it, so a worker retries with the right shape instead of returning prose. check_activity shows which agents the dispatcher woke, what they are running and how long, with a stale flag from heartbeat age. tail_worker returns the last lines of a worker log. The wake parameter on send tools decides who gets a turn, and [FINAL], [DONE], [CLOSED] or [WRAP] in a subject seals the thread.
You need Node.js 22+ and a running AgenticMail API server, plus AGENTICMAIL_API_KEY and AGENTICMAIL_MASTER_KEY. In --http mode the server binds to 127.0.0.1 and requires Authorization: Bearer <token> on every /mcp request; the token is minted on first start into ~/.agenticmail/mcp-http-token. Without an API key nothing starts.
What it helps with
- send an email or text from inside an agent
- pull a verification code out of an incoming message
- reply in the right thread
- wake only the agents that need to act
- check whether the agent you emailed actually started
Example prompts for the agent
- Send an email to
[email protected]with the subject "Weekly report" - Check the inbox and show me what arrived in the last hour
- Reply to the latest message and add
[DONE]to the subject
How to install mcp
Platform CLI
claude mcp add --env AGENTICMAIL_API_KEY=<AGENTICMAIL_API_KEY> --env AGENTICMAIL_MASTER_KEY=<AGENTICMAIL_MASTER_KEY> --env AGENTICMAIL_API_URL=<AGENTICMAIL_API_URL> --transport stdio mcp -- npx -y @agenticmail/mcpReplace <…> with your own values
Platform CLI
codex mcp add mcp --env AGENTICMAIL_API_KEY=<AGENTICMAIL_API_KEY> --env AGENTICMAIL_MASTER_KEY=<AGENTICMAIL_MASTER_KEY> --env AGENTICMAIL_API_URL=<AGENTICMAIL_API_URL> -- npx -y @agenticmail/mcpReplace <…> with your own values
Config file
{
"mcpServers": {
"mcp": {
"command": "npx",
"args": [
"-y",
"@agenticmail/mcp"
],
"env": {
"AGENTICMAIL_API_KEY": "<AGENTICMAIL_API_KEY>",
"AGENTICMAIL_MASTER_KEY": "<AGENTICMAIL_MASTER_KEY>",
"AGENTICMAIL_API_URL": "<AGENTICMAIL_API_URL>"
}
}
}
}Replace <…> with your own values
Config file
{
"servers": {
"mcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@agenticmail/mcp"
],
"env": {
"AGENTICMAIL_API_KEY": "<AGENTICMAIL_API_KEY>",
"AGENTICMAIL_MASTER_KEY": "<AGENTICMAIL_MASTER_KEY>",
"AGENTICMAIL_API_URL": "<AGENTICMAIL_API_URL>"
}
}
}
}Replace <…> with your own values
Platform CLI
gemini mcp add -e AGENTICMAIL_API_KEY=<AGENTICMAIL_API_KEY> -e AGENTICMAIL_MASTER_KEY=<AGENTICMAIL_MASTER_KEY> -e AGENTICMAIL_API_URL=<AGENTICMAIL_API_URL> mcp npx -y @agenticmail/mcpReplace <…> with your own values
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about mcp
How do I install mcp in Claude Code?
Run claude mcp add mcp -e AGENTICMAIL_API_KEY=<AGENTICMAIL_API_KEY> -e AGENTICMAIL_MASTER_KEY=<AGENTICMAIL_MASTER_KEY> -- npx -y @agenticmail/mcp. Or spell out the URL and transport: `claude mcp add --env AGENTICMAIL_API_KEY=<AGENTICMAIL_API_KEY> --env AGENTICMAIL_MASTER_KEY=<AGENTICMAIL_MASTER_KEY> --env AGENTICMAIL_API_URL=<AGENTICMAIL_API_URL> --transport stdio mcp -- npx -y @agenticmail/mcp`.
What does mcp do?
It is the AgenticMail MCP server: it hands your agent tools for email, SMS, contacts and agent-to-agent tasks. Tool calls are translated into AgenticMail API requests and the responses come back as text.
What does mcp need to run?
Node.js 22+, a running AgenticMail API server, and the AGENTICMAIL_API_KEY and AGENTICMAIL_MASTER_KEY values. In --http mode you also need the bearer token, which is created on first start.
Similar MCP servers
All MCP servers for Agent setup: memory, context, orchestration →mcp by other authors comes first.