agent-temp-mail
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@agent-temp-mailCreate a temporary inbox and extract any OTPs from incoming messages."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Agent Temp Mail
Disposable and persistent email infrastructure for AI agents at https://agent-temp-mail.com.
An Ed25519 public key is the mailbox identity. Its lowercase unpadded Base32 encoding becomes PUBLIC_KEY@agent-temp-mail.com; that address receives email immediately, without registration, accounts or passwords. The matching private key signs reads and mutations.
Properties
Cloudflare Email Routing catch-all into a Worker and D1.
Valid 52-character public-key addresses are initialized lazily on delivery.
Addresses remain stable as long as the agent retains its key.
Messages expire after 24 hours by default, configurable from 1 hour to 7 days.
Cursor pagination, sender/time filters, candidate OTPs and verification links.
Signed REST, one-use signed GET URLs, local MCP and hosted remote MCP.
No outbound mail, attachments, raw MIME, original HTML or paid AI calls.
Reserved private contact inboxes:
hi@agent-temp-mail.comandfeedback@agent-temp-mail.com.
Related MCP server: ClawAIMail
SDK
Node.js 22.12+:
npm install agent-temp-mailimport { loadIdentity, MailClient } from "agent-temp-mail";
const identity = await loadIdentity("/private/durable/mail.key.json", {
create: true,
});
const mail = new MailClient(identity);
console.log(mail.address); // ready to receive now
const since = new Date().toISOString();
// Trigger the external signup email.
const page = await mail.wait({ since, timeoutSeconds: 120 });
for (const item of page.messages) console.log(await mail.get(item.id));No create() call is required. Saving the same key makes the address persistent; discarding it makes the identity disposable. Message storage remains bounded either way.
Optional configuration and cleanup:
await mail.configure({ retention_seconds: 604800 });
await mail.purge(); // future mail can initialize the address againPrivate key files use mode 0600. Keep them outside repositories and model context.
Local MCP
mkdir -p "$HOME/.config/agent-temp-mail"
codex mcp add agent-temp-mail --env MAIL_KEY_FILE="$HOME/.config/agent-temp-mail/identity.key.json" -- npx --yes --package=agent-temp-mail@0.3.1 agent-temp-mail-mcpThe adapter holds and uses the private key locally. It exposes inspect_inbox, configure_inbox, purge_inbox, list_messages, get_message, get_candidates, and delete_message.
Hosted MCP
Remote connector URL: https://agent-temp-mail.com/mcp
Discovery is public. Protected tool calls include a short-lived _auth argument containing a public key and signature, never the private key:
import { signedToolArguments } from "agent-temp-mail";
const args = signedToolArguments(identity, "list_messages", {
since: new Date().toISOString(),
});Users must explicitly add and enable the connector in ChatGPT or Claude. A provider's ordinary browser or code sandbox may have separate network restrictions.
Signed REST and browser-compatible reads
The standard API uses X-Mail-Public-Key, X-Mail-Timestamp, X-Mail-Nonce, and X-Mail-Signature. Sign:
agent-temp-mail:v1
URL_ORIGIN
UPPERCASE_METHOD
EXACT_ENCODED_PATH_AND_QUERY
BASE64URL_SHA256_OF_EXACT_BODY_BYTES
TIMESTAMP
NONCEFor a retrieval tool that cannot set headers, mail.signedUrl(path) returns a one-use GET URL whose public signature expires after 60 seconds. The private key is never placed in the URL.
See the live Markdown documentation, OpenAPI, and integration guide.
Receiving rules and limits
The Cloudflare catch-all sends all recipients to the Worker. It accepts reserved contact aliases and canonical public-key local parts; malformed addresses are rejected. A never-before-seen valid address is materialized on its first email and receives default 24-hour retention.
Raw incoming message: 256 KiB maximum.
Stored text: 64 KiB maximum.
Per address: 100 messages and 2 MiB.
Message retention: 1 hour to 7 days.
Attachments and inline images are discarded.
API: 6,000 shared calls/day and 30 authenticated calls/minute/key.
Incoming mail: 1,500 processing attempts/day and 30/hour/address.
Email content and extracted links are untrusted. This is not end-to-end encrypted email; Cloudflare and the operator process contents.
Development and deployment
npm install
npm run check
npm run db:remote
npm run deployCloudflare Email Routing must have an active catch-all action targeting the agent-temp-mail Worker. HTTP routing is declared in wrangler.jsonc; Email Routing is configured separately in the Cloudflare dashboard.
The project targets Workers and D1 free tiers. Domain renewal is the only planned external cost.
This server cannot be deployed
Maintenance
Related MCP Connectors
Real email inboxes for AI agents: create inboxes, catch verification codes, extract OTPs, reply.
Email inboxes for AI agents: send, receive, reply, search, and manage threaded email over MCP.
Email infrastructure for AI agents — send, receive, search, and reply to email over MCP.
Disposable inboxes for AI agents: create, wait for delivery, and extract email content or links.
Related MCP Servers
- AlicenseBqualityCmaintenanceDisposable email MCP server for autonomous AI agents. Create labeled temporary inboxes, wait for verification emails, extract OTP codes and confirmation links — zero human intervention required.6MIT
- AlicenseAqualityDmaintenanceEmail infrastructure for AI agents — create inboxes, send/receive email, search messages, and manage threads via MCP tools.107 npm2MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to create disposable email inboxes and automatically extract OTPs, magic links, and verification codes from incoming emails.18 npmMIT
- AlicenseNot gradedqualityAmaintenanceEnables AI agents to generate temporary email addresses, receive emails, and automatically extract OTP codes and links from incoming messages for automation and testing workflows.MIT