Agent Email & Agent Mail: Dedicated Addresses, Inboxes, and Reputation for AI Agents
Agent email (agent mail) is email that belongs to an AI agent — its own address, its own inbox, its own reputation. Not a shared noreply, not a forwarded human mailbox.
What agent email (agent mail) is
Agent email — often shortened to agent mail — is email where the correspondent is an AI agent, not a person. The agent has its own address, its own inbox, and its own sending reputation. It sends messages, reads replies, and participates in threads — all through an API instead of a GUI.
This is different from bolting AI onto a human inbox (Gmail smart compose, Outlook Copilot) and different from a fire-and-forget send API (SendGrid, Postmark). Agent mail is bidirectional: the agent sends, the recipient replies, and the agent reads and acts on that reply. For the formal definition, see the agentmail glossary entry. If you are evaluating providers, the AgentMail API comparison covers the two platforms that define the category.
How to send agent mail with Mails.ai
You create an agent and it gets an email address. From that point the agent can send agent mail, receive replies, and read them as structured JSON events:
import { createClient } from "@mailsai/sdk" ;
const mails = createClient({ apiKey: process. env. MAILS_API_KEY });
// Create an agent — it gets its own email address immediately
const agent = await mails. agents. create( "support");
// agent.email → support@yourworkspace.mails.ai; it sends as support.yourworkspace@send.mails.ai
// Send agent mail — SPF/DKIM/DMARC handled automatically
await mails. messages. send({
from: "support",
to: "customer@example.com" ,
subject: "Your refund #812 is confirmed",
body_text: "We processed your refund. Reply here with questions.",
});
// Read the agent's inbox — replies arrive as structured events
const events = await mails. events. list({
event_type: "reply.received" ,
agent_id: "support",
limit: 10,
});
for ( const e of events. data) {
console. log( e. data. extracted_text); // clean body text
console. log( e. data. thread_id); // stable thread ID
console. log( e. injection_score); // 0.0–1.0 safety score
}Agent mail vs. transactional email
Transactional email is one-directional: your app sends a password reset or a receipt, and the conversation ends. Agent mail is bidirectional: the agent sends, the recipient replies, and the agent reads and acts on that reply. This changes the requirements:
- Per-agent identity: each agent sends agent mail from its own authenticated address, not a shared
noreply@ - Inbound parsing: replies arrive as structured data (sender, subject, body text, thread ID, attachments), not raw MIME
- Thread reconstruction: the agent reads a conversation as a thread, not disconnected messages
- Prompt-injection scanning: every inbound message is scored before the agent sees it
- Per-agent reputation: bounce and complaint rates are tracked per agent, so a misbehaving agent is paused on its own
For the architecture comparison, see the transactional vs. agent email architecture post. For the firewall that keeps agent email safe, see the agent email firewall post.
Agent mail with Python
The Python SDK provides the same agent mail capabilities. Create an agent, send agent mail, and read the inbox:
from mailsai import Client
client = Client() # reads MAILS_API_KEY from env
# Send agent mail
client. send(**{
"from": "support",
"to": "customer@example.com" ,
"subject": "Your order has shipped",
"body_text": "Tracking: 1Z999AA10123456784. Reply with any questions.",
})
# Read the agent's inbox — replies to agent mail arrive as events
events = client. list_events( event_type= "reply.received" , agent_id= "support", limit= 10)
for e in events[ "data"]:
score = e. get( "injection_score")
if score is None or score >= 0.5:
flag_for_review( e) # hold for human review
continue
handle_reply( e[ "data"][ "extracted_text"], e[ "data"][ "thread_id"])Agent mail with MCP
If your agent runs inside an MCP-capable client — Claude Code, Cursor, Cline, Windsurf, or Continue — it can use agent mail through the MCP server without writing any SDK code. The MCP server exposes send, receive, and thread operations as tools the agent calls directly, turning any MCP client into an agent mail client.
Agent mail on a custom domain
By default, agent mail is sent from an address on the shared sending domain — for example, support.yourworkspace@send.mails.ai. When your agents need to carry your brand, connect a custom domain and every agent sends agent mail as support@yourdomain.com, with SPF, DKIM, and DMARC provisioned automatically.
What every agent mail plan includes
- Dedicated agent address: each agent gets its own address with DNS authentication provisioned automatically
- Agent inbox: inbound agent mail parsed into structured JSON events with extracted text, thread IDs, and attachments
- Prompt-injection scanning: every inbound message scored before delivery to the agent
- Per-agent reputation: bounce and complaint rates tracked independently, and an agent that crosses the line is paused on its own
- Cold-email firewall: unsolicited outreach blocked at the API before transmission, protecting shared email infrastructure
Agent mail pricing
Agent mail on Mails.ai starts free. The Free tier covers one agent, 3,000 outbound emails, and 3,000 inbound replies a month — no credit card. Pro is $20/month for five agents. Scale is $99/month for unlimited agents and a dedicated IP on request. Every plan includes DNS authentication, injection scanning, and per-agent reputation. For the email API for AI agents — the endpoint reference, code samples, and interactive demos — see the API page. For the full AI email agent setup, the management layer across multiple agents, and per-agent routing, see AI email management. For the compact SDK quickstart with send-and-receive examples in TypeScript and Python, see the email API for AI agents solutions guide. For the complete guide on email for AI agents — including AI agent email addresses, structured inbound events, and deliverability — see the email for AI agents page. For setup guides by tool — Claude, Cursor, Codex, and more — see email for agents. See pricing for the full breakdown.
Frequently asked questions
What is agent email?
Is agent mail the same as agent email?
How is agent email different from a regular email API?
Does each agent get its own email address?
Can my agent read replies to its email?
Is agent email free?
How does agent email handle prompt injection?
injection_score (0.0–1.0) arrives on the event so your code branches on a number — hold anything at 0.5 or above for human review — rather than asking the LLM to notice it’s being attacked.Explore the product
Give your first agent an inbox
Free covers 3,000 emails and 3,000 inbound replies a month, with no card. Upgrade when your agents get busy.
Get your API key