Cloudflare Email Service vs Trotta Mail: build the agent inbox, or use one
Pick Cloudflare Email Service if your agent already runs on Workers, you own a domain in Cloudflare and you want to design storage and rules yourself. Pick Trotta Mail if you want a finished inbox: storage, threads, an API and MCP to read it, screening before delivery and human review.
Updated
Cloudflare Email Service is two building blocks: Email Routing forwards incoming mail or hands it to a Worker, and Email Sending (marked beta) sends mail. The Agents SDK adds onEmail, reply helpers and address-based routing to agent instances. Trotta Mail is the finished inbox.
Checked against Cloudflare's Email Service and Agents docs on December 3, 2026. Prices are as listed on 2026-12-03.
Does Cloudflare give an agent an inbox?
Not as a hosted mailbox with a read API in Email Service. A message arrives at your code, and what you keep is up to you. Cloudflare publishes Agentic Inbox, an open source reference app you deploy to your own account, with a web client, drafts that need confirmation and an MCP server.
Read its README before you share it: whoever passes the Access policy can reach every mailbox in the app, MCP included. There is no per-mailbox authorization.
What do you build yourself?
| Job | Cloudflare Email Service | Trotta Mail |
|---|---|---|
| Storage, search, threads | You build it. | Included. |
| A read API or tools for the model | You build it. | REST, MCP, SDKs. |
| Sender authentication | Requires an SPF or DKIM pass, honors enforcing DMARC, passes results to your Worker. | Checked and reported in the verdict. |
| Spam and phishing | Mail from IP addresses on block lists is rejected. Content filtering is yours. | Screened before acceptance. |
| Prompt injection | Not described in the Email Service docs. | Screened on every plan. |
| Review queue for humans | You build it. | Held mail, released by a human. |
| Outgoing content checks | Not described. Suppression lists and quotas apply. | Secrets and sensitive data. |
| Domain | Required, in your Cloudflare account. | Optional. Your own on paid plans. |
How is each priced?
Cloudflare: inbound routing is unlimited on both Workers plans, and your Worker is billed as a Worker. On Workers Free, sending reaches only destination addresses you have verified. Workers Paid, from $5 a month, includes 3,000 outbound emails a month, then $0.35 per 1,000. A message can be up to 25 MiB.
Trotta Mail: $0 for 3 agent inboxes and 3,000 emails a month, $20 for 10 inboxes and 10,000, $200 for 150 and 150,000. Received and sent both count.
Where Cloudflare is the better choice
- Price at scale. No charge per inbox, and many agents can share one domain by address, such as
support@andsales@. - One platform. Mail, agent state and code sit together, and signed reply headers route an answer back to the same agent instance.
- Full control of what is stored, where and for how long.
- SMTP and a send binding for application mail as well as agent mail.
Where Trotta Mail is the better choice
- You want to ship the agent, not a mail client. Verification codes, quoted history, attachments as text and calendar invitations are already handled.
- Strangers can write to it. Valid sender authentication says which domain sent a message, not that it is safe for a model to read.
- Your agent is not a Worker. Claude Code, Codex, a Python job or any MCP client connects directly.
- No domain to start.
No screening catches everything. Whichever you choose, treat mail as untrusted input.
Can a Cloudflare agent use Trotta Mail as its inbox?
- Leave your existing domain on Email Routing and create a Trotta Mail inbox for the agent.
- Register your Worker's URL with
POST /v1/webhooks. Thewhsec_secret is shown once. - Store it as a Worker secret named
TROTTA_MAIL_WEBHOOK_SECRET. - Verify each call, then let the agent fetch the message by id. Add
message.heldtoevent_typesto hear about held mail; it carries no content.
// npm install trotta-mail
import { verifyWebhook } from "trotta-mail";
export default {
async fetch(request: Request, env: { TROTTA_MAIL_WEBHOOK_SECRET: string }): Promise<Response> {
const raw = await request.text();
let event;
try {
event = await verifyWebhook(raw, request.headers, env.TROTTA_MAIL_WEBHOOK_SECRET);
} catch {
return new Response("bad signature", { status: 400 });
}
if (event.type === "message.received") {
const message = event.data.message!;
console.log(message.id, message.verdict.action, message.subject);
// Hand message.id to your agent here.
}
return new Response("ok");
},
};We ran this in a local Workers runtime against a local copy of our server: signed events returned 200 and an unsigned request 400. To move a domain's mail to Trotta Mail instead, add the domain on a paid plan; changing its MX records takes it off Email Routing. Cloudflare is a trademark of its owner.
Questions
Can Cloudflare Email Routing receive email for an AI agent?
Yes. A routing rule sends mail to a Worker, and the Agents SDK passes it to your agent's onEmail method. You need a domain onboarded to Email Service.
Is Cloudflare email free for agents?
Receiving is unlimited on Workers Free and Paid. Sending to arbitrary addresses needs Workers Paid, from $5 a month, as listed on 2026-12-03.
Can a Worker reply to any incoming email?
Not always. The docs say reply() needs the incoming message to have a valid DMARC result, and allows one reply per message event. A later message goes through the send binding.
Is Agentic Inbox a hosted service?
No. It is a reference application under an open source license that you deploy and operate in your own Cloudflare account.