Concepts, patterns, and recipes for outreach agents.
Learn how to provision inboxes, set up custom domains, ship deliverable email, integrate with major AI frameworks, and handle the awkward edges of agent-driven outreach.
Getting started
What it is, your first inbox, API keys, and the agent skill.
What is myagentmail?
A multi-tenant email API purpose-built for AI agents. Real inboxes with IMAP and SMTP, real threading, real custom domains — none of the compromises you'd hit trying to use a transactional provider fo
Creating your first inbox
About ninety seconds end-to-end.
API keys & scopes
Four key tiers. Pick the narrowest one that fits the job.
Inboxes
Capabilities, threading, drafts, allowlists, and 2FA.
Deliverability
Custom domains, SPF/DKIM/DMARC, warming, and spam triage.
Custom domain setup
Send as [email protected] instead of [email protected], without losing any existing thread history.
SPF, DKIM, and DMARC
What the three authentication standards do, and what myagentmail needs from each.
Domain warming
A new domain has no sending reputation. Ramp slowly or you'll land in spam.
Operations
Limits, bounces, workspaces, and human-in-the-loop.
TypeScript SDK
Install myagentmail from npm and get typed access to every endpoint in one import. View on npm
Install the agent skill
Drop-in Claude Code / Cursor / OpenClaw skill that teaches your coding assistant the full myagentmail API surface in one file.
Handling inbound email
Three ways to receive mail in your agent. They compose — you can use more than one.
Threaded conversations
How myagentmail assembles a thread, and how to stay in one when you reply.
Human-in-the-loop workflows
Add approval gates to agent-generated email so a human signs off before anything goes out.
Workspaces for multi-tenant email
Isolate inboxes and domains across your customers without opening a new myagentmail account per customer.
Allowlists & blocklists
Filter who can reach an agent's inbox before the message hits your downstream processing.
Receiving 2FA codes inline
The flagship WebSocket use case: an agent fills out a signup form, waits for the verification email, extracts the code, enters it — all in one turn without a public webhook receiver.
Why my mail is landing in spam
The most common reasons, in order of how often we see them.
MX records without breaking your primary domain
Your main company domain probably already has mail. Here's how to add myagentmail without blowing up your existing inbox.
Rate limits & plan limits
Two kinds of ceilings to be aware of.
Bounces and auto-pause
We auto-pause sending from an inbox that's bouncing too much, to protect your domain reputation.
Domain verification failures
Common reasons a domain gets stuck in pending and how to fix each.
Avoiding duplicate sends
What to do when your agent retries a send and you're not sure whether the first one went through.
MCP server
Plug myagentmail into Claude Desktop, Cursor, Windsurf, Cline, or any MCP-compatible client. Your AI assistant gets a full set of email tools instantly.
Vercel AI SDK
Wire myagentmail into the Vercel AI SDK as tool definitions for generateText and streamText.
LangChain
Wrap myagentmail endpoints as LangChain tools (TS or Python).
OpenAI function calling
JSON schema function definitions you can drop straight into the OpenAI Chat Completions or Responses API.
Anthropic tool use
Tool definitions for the Claude Messages API.
OpenClaw extension
Drop a single TypeScript file into ~/.openclaw/extensions/ to give every OpenClaw agent native myagentmail tools.
Example: Inline 2FA-code signup
Sign up for a third-party service on behalf of a user, wait for the verification code email, extract the code, and complete the signup — all in one agent turn without any public webhook receiver.
Example: Customer support triage
Watch a support inbox, classify each new message into a category, draft a reply, and either auto-send routine answers or hand off to a human reviewer for sensitive ones.
Example: Lead enrichment + personalized outreach
Pull a list of leads from a CRM, enrich each with public data, and send a personalized opener that references something specific about their company.
Example: Calendar booking via email
When a prospect emails "let's chat next week", an agent reads the message, checks calendar availability, replies with three slot options, and books on confirmation.
Cloudflare DNS setup
Adding myagentmail's records in the Cloudflare dashboard.
AWS Route 53 setup
Adding myagentmail's records to an existing Route 53 hosted zone.
GoDaddy DNS setup
Adding records in the GoDaddy domain manager.
Namecheap DNS setup
Adding records to a Namecheap-managed domain.
Examples
End-to-end recipes you can lift into your own code.
Example: Build an AI lead agent in 6 API calls
An end-to-end recipe for building a Gojiberry-style AI sales agent on top of MyAgentMail. The agent watches LinkedIn for buying-intent posts that match a plain-English firing rule, and sends a persona
Example: Cold outreach with reply tracking
Send personalized cold emails, watch for replies, and trigger follow-ups when nothing comes back after N days.
Looking for the API spec?
The full REST + WebSocket reference lives in the API documentation.