agentmail — Claude Code skill: AgentMail SDK code guidance
Teaches your agent to write code against the AgentMail TypeScript or Python SDK: inboxes, messages, webhooks, domains.
npx skills add agentmail-to/agentmail-skills --skill agentmail -a claude-codeWhat agentmail does
AgentMail is an email API built for AI agents. This skill gives the coding agent a short map of the SDK so it stops inventing method names. Inside are starting examples for TypeScript and Python, calling conventions, and a list of API traps worth reading before writing code.
An agent working with it can create an inbox, send mail, pull the reply, set up webhooks, manage domains. Deeper references cover Svix signature checks, WebSocket events, allow and block lists, and triage for mail that never arrived. Credentials live in AGENTMAIL_API_KEY.
Watch the sign-up call. Running sign_up again with the same human_email rotates the API key and kills the old one instantly, so it must never run inside a retry loop or a key check. Also: the attachment method hands back a signed URL on cdn.agentmail.to that expires in about an hour, not the file bytes. The skill is scoped to SDK code work — direct mailbox operations, CLI use and MCP setup sit outside it. You need the agentmail package, from npm install agentmail or pip install agentmail.
What it helps with
- create an agent inbox programmatically
- send a message and read the reply without quoted history
- set up a sending domain with DNS records
- verify Svix signatures on incoming webhooks
- trace why an agent's email never arrived
Example prompts for the agent
- Write Python code that creates an inbox named
supportand sends a message with the agentmail SDK - Port this script to the TypeScript agentmail SDK and fix the message-delete error
- Go through the agentmail skill and tell me why my agent's email is bouncing
How to install agentmail
1Skills CLI (Vercel)
npx skills add agentmail-to/agentmail-skills --skill agentmail -a claude-code2Manually: put the files in place
~/.claude/skills/agentmail/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/agentmail/
1Skills CLI (Vercel)
npx skills add agentmail-to/agentmail-skills --skill agentmail -a codex2Manually: put the files in place
.agents/skills/agentmail/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add agentmail-to/agentmail-skills --skill agentmail -a cursor2Manually: put the files in place
.cursor/skills/agentmail/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install agentmail-to/agentmail-skills agentmail2Manually: put the files in place
.github/skills/agentmail/SKILL.md1Skills CLI (Vercel)
npx skills add agentmail-to/agentmail-skills --skill agentmail -a gemini-cli2Platform CLI
gemini skills install https://github.com/agentmail-to/agentmail-skills --path agentmailManually: put the files in place
.devin/skills/agentmail/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add agentmail-to/agentmail-skills --skill agentmail -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about agentmail
How do I install agentmail in Claude Code?
Run npx skills add agentmail-to/agentmail-skills --skill agentmail -a claude-code. The skill lands at ~/.claude/skills/agentmail/SKILL.md.
What does agentmail do?
It hands the agent SDK guidance for AgentMail in TypeScript and Python, covering inboxes, messages, domains, webhooks, WebSocket events and deliverability triage.
Does it work without an API key?
For normal SDK calls you set AGENTMAIL_API_KEY. Agent sign-up is the exception: signUp needs no key and returns one, which you then use for verification.