Index of every page on this site: llms.txt
All skills
agentmail-to avatar

/agentmail

@8b3d9ae
Run it yourself

Build with the AgentMail TypeScript or Python SDK for inbox, message, thread, draft, attachment, domain, allow/block list, pod, webhook, and WebSocket workflows, including programmatic agent sign-up, domain/DNS administration, and deliverability triage (bounces, spam, blocked mail). Use when implementing or reviewing AgentMail API code; do not use for direct mailbox operations, CLI usage, MCP setup, or framework-toolkit integration.

Use this Skill: https://skilld.dev/gh/agentmail-to/agentmail-skills/agentmail

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencesadmin.md

≈927 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Admin: Domains, Allow/Block Lists, and IMAP/SMTP

These are the admin-adjacent SDK calls with enough sharp edges to document directly. For scoped API keys, permissions, metrics, and pod administration, consult the current AgentMail API reference. For the agent sign-up flow, see the main SKILL.md.

Domains

Set feedback_enabled / feedbackEnabled to true on create to route bounce and complaint notifications to your inboxes (optional in the API and SDKs; the CLI requires the flag). The response's records field lists the SPF/DKIM/DMARC verification records to add at your registrar.

domain = client.domains.create(domain="yourdomain.com", feedback_enabled=True)
# domain.records -> list of VerificationRecord objects
client.domains.verify(domain_id=domain.domain_id)
const domain = await client.domains.create({ domain: "yourdomain.com", feedbackEnabled: true });
// domain.records -> verification records
await client.domains.verify(domain.domainId);

Custom domains require a paid plan; @agentmail.to inboxes are free and need no verification.

DKIM/SPF gotchas

  • AWS Route 53 DKIM records: the DKIM TXT value must be split into two quoted strings with no space between them. "first-part""second-part" is correct; "first-part" "second-part" (with a space) breaks verification.
  • One SPF record per domain: a domain can only have a single SPF TXT record. If you already send mail through another service, merge AgentMail's include: into the existing record instead of adding a second one, e.g. v=spf1 include:spf.agentmail.to include:other.com ~all.

Allow/block lists

Entries are flat: one (inbox_id, direction, type, entry) tuple per call — there is no batch update and no .allow / .block sub-namespace. direction is "send", "receive", or "reply". type is "allow" or "block"; block takes priority over allow. create also accepts an optional reason for documenting why an entry was added.

client.inboxes.lists.create(inbox_id="agent@agentmail.to", direction="receive", type="allow", entry="boss@company.com")
client.inboxes.lists.create(inbox_id="agent@agentmail.to", direction="receive", type="block", entry="spammer@example.com", reason="repeated abuse")

entries = client.inboxes.lists.list(inbox_id="agent@agentmail.to", direction="receive", type="allow")
entry = client.inboxes.lists.get(inbox_id="agent@agentmail.to", direction="receive", type="allow", entry="boss@company.com")
client.inboxes.lists.delete(inbox_id="agent@agentmail.to", direction="receive", type="allow", entry="boss@company.com")
await client.inboxes.lists.create("agent@agentmail.to", "receive", "allow", { entry: "boss@company.com" });
await client.inboxes.lists.create("agent@agentmail.to", "receive", "block", { entry: "spammer@example.com", reason: "repeated abuse" });

const entries = await client.inboxes.lists.list("agent@agentmail.to", "receive", "allow");
await client.inboxes.lists.delete("agent@agentmail.to", "receive", "allow", "boss@company.com");

To replace an allow/block entry, delete the old one and create the new one — there is no bulk update.

IMAP and SMTP

AgentMail inboxes are also reachable over standard IMAP and SMTP for legacy mail clients. Authenticate with the inbox address as the username and an API key as the password.

Protocol Host Port Auth
IMAP imap.agentmail.to 993 (SSL) inbox address + API key
SMTP smtp.agentmail.to 465 (SSL) inbox address + API key

See https://docs.agentmail.to/imap-smtp for further setup details.

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

2 warnings1mo5 checks · Risk SAFE
  • Gen Agent Trust Hub1mo

    The skill provides an SDK for the AgentMail email platform, enabling AI agents to manage inboxes, send messages, and handle webhooks. It follows security best practices by recommending environment variables for secret management and explicitly warning developers to treat all incoming email content as untrusted. No malicious patterns or unauthorized behaviors were detected.

  • Socket1mo

    No alerts

  • Snyk1mo

    Risk: MEDIUM · 1 issue

  • Runlayer9mo

    2/3 files flagged

  • ZeroLeaks7mo

    3 findings · Score: 69/100

Signed by skilld at 8b3d9ae. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 4 days ago.

Activeupdated 4 months ago

README badge

README badge for agentmail-to/agentmail-skills

AgentMail is an API-first email platform that gives AI agents dedicated email inboxes for sending, receiving, and managing messages programmatically. The SDK supports multi-tenant pods, label-based organization, draft creation for human approval, attachment handling, and real-time event notifications via webhooks or websockets. Available in TypeScript/Node and Python.

Generated from the current SKILL.md.

Does this support both TypeScript and Python?
Yes. The SDK is available for both Node.js/TypeScript (npm install agentmail) and Python (pip install agentmail).
Can I use custom domains for agent email addresses?
Yes. You can create inboxes with a custom username and domain (e.g., support@yourdomain.com) or let AgentMail auto-generate an address.
How do I set up real-time email notifications?
AgentMail supports both webhooks (HTTP-based, requires a public URL) and websockets (persistent connection, no public URL needed). See the webhooks.md and websockets.md reference files.
Does this support human-in-the-loop workflows?
Yes. You can create draft messages for human approval before sending them, then convert the draft to a sent message via the API.
How does multi-tenant isolation work?
Use pods to create isolated inbox namespaces per customer. Each pod gets its own set of inboxes scoped within it, useful for SaaS platforms.

Generated from the current SKILL.md. These answers refresh after source changes.