@kody/agent-mail
AgentMail inboxes for agents: create/list inboxes, messages, threads, and Svix webhook ingress.
- Integrations
- agentmail
- inbox
- webhooks
- agents
- integrations
- Version
- 1.0.0
- License
- Published
- September 10, 2026
- Pinned commit
d785c2d- Rating
- No ratings yet
- Forks
- 3
- Adaptation effort
- —
README
Agent docs@kody/agent-mail
Intent
Thin AgentMail API helpers for giving agents their own email inboxes: list and
create inboxes, read messages and threads, send or reply with an explicit
confirm / dryRun guard, register AgentMail webhooks, and handle inbound
Svix deliveries on the package inbound webhook. Uses the user secret
agentmailApiKey against api.agentmail.to (EU host api.agentmail.eu is
also supported for secret host approval). Does not auto-send on inbox create.
What it does
- List and create AgentMail inboxes (optional
clientIdidempotency) - Read messages and threads for an inbox
- Send or reply with
dryRunpreview or liveconfirm - Register AgentMail-side webhooks and verify inbound Svix deliveries
Prerequisites / setup
- Create an AgentMail API key, then save it at
secrets/new
with
allowedHosts=api.agentmail.to(addapi.agentmail.euif you use the EU API). - Approve host
api.agentmail.toif prompted. - Optional for verified inbound webhooks: save the AgentMail webhook signing
secret (starts with
whsec_) asagentmailWebhookSecretat secrets/new. - Agents: see
AGENTS.mdfor import paths and smoke checks.
Webhooks
AgentMail delivers events over Svix (svix-id, svix-timestamp,
svix-signature). Kody platform webhook verification only supports
hmac-sha256, so this package declares the inbound webhook without
platform verification and verifies Svix inside ./handle-webhook when
agentmailWebhookSecret is present.
- After publish, mint the package webhook URL with
webhookUrlMintandwebhookName: "inbound"(the URL is a credential — do not paste it into chat or commit it). - Create an AgentMail webhook pointing at that URL for
event_typesincludingmessage.received(and any other types you need). See Create Webhook. - Save the returned AgentMail
secret(whsec_…) as user secretagentmailWebhookSecret. - Verification details: Webhook verification.
You can also register the AgentMail-side webhook via this package's
create-webhook helper with confirm: true (or dryRun: true) once you have
a minted ingress URL.
Done when
agentmailApiKeyis saved andapi.agentmail.tois approved- You can list inboxes (and optionally whoami) without errors
- Send / reply / create-webhook refuse live calls unless
dryRun: trueorconfirm: true - Creating an inbox does not auto-send mail
- Optional: inbound Svix verification works when
agentmailWebhookSecretis set
Branding
Listing icons use the official AgentMail mark from the
agentmail.to favicon (white fedora agent silhouette on
black). The unmodified source is in brand/agentmail-favicon.png.
Report this listing
Log in to report this listing.