other · Listed · Found · 191 endpoints · Gateway-eligible
API Reference
API Reference
MPP endpoints published at https://docs.agentmail.to.
Indexed from this operator's public /.well-known/x402.json. Found is not operator-owned and is not attested. Claim or opt out.
Agent Read · Cleared Index
ROUTE
Route when you need other at published x402 prices.
confidence
78%
source
signal
Index before you pay. Same payload for agents:
GET /api/cleared/agent-read?slug=api-reference-hbwz
When to call
- Need other via x402 and want Cleared-indexed payTo with a live scorecard.
- MPP endpoints published at https://docs.agentmail.to.
Risks
- Found — not operator-owned; claim status unknown.
- No Cleared settlement receipt on file yet.
- No Gateway traffic yet — market share unproven.
Price posture
191 endpoints — confirm price on manifest before pay.
Category · Gateway
other · no Gateway routes yet — early / unproven on Cleared market share.
Endpoint hints
POST /v0/agent/sign-upCreate a new agent organization with an inbox and API key. This endpoint is for signing up for the first time. If you've already signed up, you're all set — jus
POST /v0/agent/humanAttach a human to an unverified agent organization. A 6-digit OTP is sent to the human's email, which you then submit to the verify endpoint. Use it after sign
POST /v0/agent/verifyVerify an agent organization using the 6-digit OTP sent to the human's email during sign-up. On success, the organization is upgraded from `agent_unverified` t
GET /v0/inboxes/{inbox_id}/filesLists the inbox's files in path order, pending ones included, optionally only those whose path starts with `path_prefix`. A prefix matches characters, not whole
POST /v0/inboxes/{inbox_id}/filesStarts an upload: creates a pending file at `path` and returns an `upload` to `PUT` its bytes to. The bytes go straight to storage, not through the API. Then ca
POST /v0/inboxes/{inbox_id}/files/{file_id}/completeMakes a pending file `ready` once its bytes are uploaded, and returns it, with its `download_url` if the key has `file_read`. Calling it on a file that is alrea
GET /v0/inboxes/{inbox_id}/files/{file_id}Gets a file. A `ready` file comes with a fresh `download_url`, valid for up to an hour. A get reads the region that serves the request, so for about a second a
GET /v0/inboxes/{inbox_id}/files/{file_id}Deletes a file, pending or `ready`, and frees its path at once. Its bytes are deleted, and its space given back to the organization's quota, within seconds. A d
Evidence (Cleared)
- → Intake verified · Gateway-eligible
- → Trust 70/100 · pass · tier listed
- → Protocol mpp
- → Manifest reachable · schema valid
- → Found listing — indexed from public x402.json, not operator-attested.
Endpoints
Sign Up
Not used$MeteredPOST https://docs.agentmail.to/v0/agent/sign-upCreate a new agent organization with an inbox and API key. This endpoint is for signing up for the first time. If you've already signed up, you're all set — just use your existing API key. A 6-digit OTP is sent to the human's email for verification. The new organization starts with 1 inbox, no custom domains, and 10 emails per day, which can be sent only to `human_email` until the organization is verified. `human_email` is optional. Without it, the inbox can receive email but cannot send to anyone until a human is attached with the attach human endpoint or, for a US-region inbox, claims it in the AgentMail Console with the API key (see [How do I claim my agent's inbox?](https://docs.agentmail.to/knowledge-base/claiming-agent-inbox)). There is also no way to recover the API key, so store it durably. Calling sign-up again without `human_email` creates a new organization, which needs a different `username`: the original username stays with the lost organization's inbox. This endpoint is idempotent. Calling it again with the same `human_email` will rotate the API key and resend the OTP if expired. The returned API key has limited permissions until the organization is verified via the verify endpoint. **CLI:** ```bash agentmail agent sign-up --human-email user@example.com --username my-agent ```
Attach Human
Not used$MeteredPOST https://docs.agentmail.to/v0/agent/humanAttach a human to an unverified agent organization. A 6-digit OTP is sent to the human's email, which you then submit to the verify endpoint. Use it after signing up without a `human_email`. Once the human is attached, the organization can send email to that human only, and verification lifts the remaining restrictions. For up to 5 minutes after attaching, sends to the human can still be rejected with a `429` daily send limit error while the API key's cached limits catch up. Wait and retry. Calling it again with the same `human_email` does not rotate the API key. It resends the OTP if it was never delivered, or issues a new one if it expired. While the current OTP is still valid, calling it again keeps that OTP and its attempt count. If all 10 attempts are used up, wait until the OTP expires, 24 hours after it was issued, then call it again for a new one. Calling it with a different `human_email` replaces the attached human and sends the new human an OTP. An organization can replace its human at most 2 times. Only available until the organization is verified. **CLI:** ```bash agentmail agent attach-human --human-email user@example.com ```
Verify
Not used$MeteredPOST https://docs.agentmail.to/v0/agent/verifyVerify an agent organization using the 6-digit OTP sent to the human's email during sign-up. On success, the organization is upgraded from `agent_unverified` to `agent_verified`, the send allowlist is removed, and the Free plan's entitlements are applied: 3 inboxes and 100 emails per day, at first to at most 3 distinct recipients in the first hour, 5 in the first day, and 10 in the first week. The OTP expires after 24 hours and allows a maximum of 10 attempts. If the OTP expired, call the attach human endpoint with the same `human_email` to get a new one without rotating the API key. Once all 10 attempts are used, even the correct OTP is rejected, and attach human keeps returning the same OTP until it expires, so wait for it to expire before asking for a new one. An organization that signed up without a `human_email` has no OTP until a human is attached. If you run into any difficulties receiving the OTP code, you can also create an account on [console.agentmail.to](https://console.agentmail.to) using the human email address you provided to verify your account. **CLI:** ```bash agentmail agent verify --otp-code 123456 ```
List Files
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/filesLists the inbox's files in path order, pending ones included, optionally only those whose path starts with `path_prefix`. A prefix matches characters, not whole segments: `reports/q` matches `reports/q3.pdf`. Items carry no download URL; get a file for one. The list is read in the region that serves the request, so a file created or deleted a moment ago may not show yet. Expired files never show. Requires the `file_read` permission.
Create File
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/filesStarts an upload: creates a pending file at `path` and returns an `upload` to `PUT` its bytes to. The bytes go straight to storage, not through the API. Then call Complete File to make the file `ready`. Retry-safe: sending the identical request again (same `path`, `size`, `sha256`, `content_type` and `expires_at`) returns the existing file with `200` instead of `201`: a pending one with a fresh `upload`, or a `ready` one without. If its bytes were uploaded but the upload was never completed, it is completed then. A different request at a path whose file is still pending and has no bytes replaces that file; at any other taken path it returns `409`. The file counts against the organization's Drive quota from creation, pending or not: 1 GiB and 10,000 files by default. A file that doesn't fit returns `403` with code `limit_exceeded`. Deleting a file frees its space within seconds. Expired files count until a create needs their space: a create that doesn't fit first gives back what expired files hold, a batch at a time, so retry a refusal while many expired files remain. Requires the `file_create` permission, which an unverified organization's keys don't have at any scope until it completes agent verification. A key without `file_read` can still create files, but gets the plain `409` at any taken path, even for an identical request at a file it didn't create. Agent Drive is in AgentMail Labs, available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`). Organizations that have not joined Labs receive a `403`.
Complete File
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/files/{file_id}/completeMakes a pending file `ready` once its bytes are uploaded, and returns it, with its `download_url` if the key has `file_read`. Calling it on a file that is already `ready` returns the file. Returns `409` if the bytes haven't been uploaded yet, or if what was uploaded doesn't match the file's `size` and `sha256`. Returns `404` for a file that has expired or was deleted, including a pending file not completed within a day of its creation. Requires the `file_create` permission. Only a key with `file_read`, or the key that created the file, can complete it; any other key gets `404`.
Get File
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/files/{file_id}Gets a file. A `ready` file comes with a fresh `download_url`, valid for up to an hour. A get reads the region that serves the request, so for about a second after a delete it can still return the deleted file. A file that has expired returns `404` at once. Requires the `file_read` permission.
Delete File
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/files/{file_id}Deletes a file, pending or `ready`, and frees its path at once. Its bytes are deleted, and its space given back to the organization's quota, within seconds. A download URL signed before the delete keeps working until it expires, at most an hour. Deleting a file that is already gone returns `404`. Requires the `file_delete` permission. Only a key with `file_read`, or the key that created the file, can delete it; any other key gets `404`.
List Inboxes
$MeteredGET https://docs.agentmail.to/v0/inboxes**CLI:** ```bash agentmail inboxes list ```
Create Inbox
$MeteredPOST https://docs.agentmail.to/v0/inboxes**CLI:** ```bash agentmail inboxes create --display-name "My Agent" --username myagent --domain agentmail.to ```
Search Inboxes
$MeteredGET https://docs.agentmail.to/v0/inboxes/searchSearches inboxes in the organization by address or display name, ranked by relevance. Each word in the query matches the start of a word in the address or display name, so `sup` matches `support@example.com` but `port` does not. An exact address match always ranks first. `limit` cannot exceed 100. A page can be empty and still carry a `next_page_token`; keep paging until the token is absent.
Get Inbox
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}**CLI:** ```bash agentmail inboxes get --inbox-id <inbox_id> ```
Update Inbox
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}**CLI:** ```bash agentmail inboxes update --inbox-id <inbox_id> --display-name "Updated Name" ``` To deactivate an inbox, set `status` to `deactivated`; set it back to `active` to reactivate it. To deactivate it later, set `deactivate_at`. See [Deactivating an inbox](/inboxes#deactivating-an-inbox).
Delete Inbox
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}Deletion is asynchronous. A `202` means it has started. While it runs, requests for this inbox return `409` `resource_deleting`. Poll `GET /v0/inboxes/{inbox_id}` until it returns `404`, then the address is free. If the inbox still has its own API keys, delete returns `409` `cannot_delete`: revoke those keys first. **CLI:** ```bash agentmail inboxes delete --inbox-id <inbox_id> ```
Authorize Inbox
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/authorizeAuthorizes the AgentID sign-in a client is already waiting in, for the inbox in the path, and returns the ID of the pending public key it will activate. Read the key with Get API Key. A repeat for the same token, inbox, and bearer returns the same key ID. A `403` `AppSignupLimitError` means the app accepts no more sign-ups from your organization.
List Threads
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/threadsLists threads in the inbox, most recent first. Pass `senders`, `recipients`, or `subject` to filter by substring. Filtered requests are served by search, which caps `limit` at 100. For relevance-ranked full-text search, use `Search Threads`. **CLI:** ```bash agentmail inboxes threads list --inbox-id <inbox_id> ```
Search Threads
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/threads/searchFull-text search across threads in the inbox, ranked by relevance. The query is matched against senders, recipients, and subject (substring) and the message body (tokenized full text). Spam, trash, blocked, and unauthenticated threads are always excluded. `limit` cannot exceed 100.
Get Thread
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/threads/{thread_id}**CLI:** ```bash agentmail inboxes threads get --inbox-id <inbox_id> --thread-id <thread_id> ```
Update Thread
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/threads/{thread_id}Updates thread labels. Cannot add or remove system labels (sent, received, bounced, etc.). Rejects requests with a `422` for threads with 100 or more messages.
Delete Thread
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/threads/{thread_id}Permanently deletes a thread and all of its messages. **CLI:** ```bash agentmail inboxes threads delete --inbox-id <inbox_id> --thread-id <thread_id> ```
Get Attachment
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/threads/{thread_id}/attachments/{attachment_id}**CLI:** ```bash agentmail inboxes threads get-attachment --inbox-id <inbox_id> --thread-id <thread_id> --attachment-id <attachment_id> ```
List Messages
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/messagesLists messages in the inbox, most recent first. Pass `from`, `to`, or `subject` to filter by substring. Filtered requests are served by search, which caps `limit` at 100. For relevance-ranked full-text search across sender, recipients, subject, and message body, use `Search Messages`. **CLI:** ```bash agentmail inboxes messages list --inbox-id <inbox_id> ```
Search Messages
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/searchFull-text search across messages in the inbox, ranked by relevance. The query is matched against the sender, recipients, and subject (substring) and the message body (tokenized full text). Spam, trash, blocked, and unauthenticated messages are always excluded. `limit` cannot exceed 100.
Get Message
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/{message_id}**CLI:** ```bash agentmail inboxes messages get --inbox-id <inbox_id> --message-id <message_id> ```
Update Message
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/{message_id}**CLI:** ```bash agentmail inboxes messages update --inbox-id <inbox_id> --message-id <message_id> --add-labels read --remove-labels unread ```
Delete Message
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/{message_id}Permanently deletes a message. **CLI:** ```bash agentmail inboxes messages delete --inbox-id <inbox_id> --message-id <message_id> ```
Create Agent Armor Feedback
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/{message_id}/agent-armor/feedbackTell us whether Agent Armor's verdict on a message was right. The message needs a completed result. A message accepts up to 20 pieces of feedback. Requires permission to read the message.
Release Agent Armor Message
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/{message_id}/agent-armor/releaseRelease a message Agent Armor held for review in hold mode: your agents are sent its `message.received` event, `message.security.override` is sent too, in either order, and its `agent-armor-held` label is removed. Only a message whose verdict is `review` and that is still held can be released; anything else answers `409`. Repeating a release with the same reason and the same API key returns the first release; any other repeat answers `409`. Requires the opt-in `agent_armor_release` permission and permission to read the message. An organization admin can also release from the console.
Batch Get Messages
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/batch-getFetch metadata for up to 500 messages in one request. Missing or restricted IDs are silently omitted; compare `count` against `limit` to detect misses. **CLI:** ```bash agentmail inboxes messages batch-get --inbox-id <inbox_id> --message-ids <id1> --message-ids <id2> ```
Batch Update Messages
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/batch-updateApply one label change to up to 50 messages in a single request. The same add_labels and remove_labels apply to every message id, and at least one of them must be provided. The update is atomic: either all resolved messages are updated or none are. Missing or restricted ids are silently excluded; compare `count` against `limit` to detect exclusions. **CLI:** ```bash agentmail inboxes messages batch-update --inbox-id <inbox_id> --message-ids <id1> --message-ids <id2> --add-labels read --remove-labels unread ```
Get Attachment
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/{message_id}/attachments/{attachment_id}**CLI:** ```bash agentmail inboxes messages get-attachment --inbox-id <inbox_id> --message-id <message_id> --attachment-id <attachment_id> ```
Get Raw Message
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/{message_id}/raw**CLI:** ```bash agentmail inboxes messages get-raw --inbox-id <inbox_id> --message-id <message_id> ```
Send Message
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/send**CLI:** ```bash agentmail inboxes messages send --inbox-id <inbox_id> --to recipient@example.com --subject "Hello" --text "Body" ```
Reply To Message
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/{message_id}/reply**CLI:** ```bash agentmail inboxes messages reply --inbox-id <inbox_id> --message-id <message_id> --text "Reply text" ```
Reply All Message
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/{message_id}/reply-all**CLI:** ```bash agentmail inboxes messages reply-all --inbox-id <inbox_id> --message-id <message_id> --text "Reply text" ```
Forward Message
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/messages/{message_id}/forward**CLI:** ```bash agentmail inboxes messages forward --inbox-id <inbox_id> --message-id <message_id> --to recipient@example.com ```
List Drafts
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/drafts**CLI:** ```bash agentmail inboxes drafts list --inbox-id <inbox_id> ```
Create Draft
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/draftsCreate a draft. Supply `in_reply_to` to create a reply draft (with `reply_all` to address the whole thread), whose recipients, subject, and threading are derived from the referenced message, or `forward_of` to create a forward draft, which derives the subject, threading, and forwarded content from the source but keeps recipients caller-supplied. **CLI:** ```bash agentmail inboxes drafts create --inbox-id <inbox_id> --to recipient@example.com --subject "Draft subject" --text "Draft body" ```
Get Draft
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/drafts/{draft_id}**CLI:** ```bash agentmail inboxes drafts get --inbox-id <inbox_id> --draft-id <draft_id> ```
Update Draft
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/drafts/{draft_id}Edit fields on an existing draft. Passing `null` clears a field (or `[]` for a recipient field); `send_at: null` un-schedules a scheduled draft. A draft that is already being sent cannot be edited. **CLI:** ```bash agentmail inboxes drafts update --inbox-id <inbox_id> --draft-id <draft_id> --subject "Updated subject" ```
Delete Draft
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/drafts/{draft_id}**CLI:** ```bash agentmail inboxes drafts delete --inbox-id <inbox_id> --draft-id <draft_id> ```
Get Attachment
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/drafts/{draft_id}/attachments/{attachment_id}**CLI:** ```bash agentmail inboxes drafts get-attachment --inbox-id <inbox_id> --draft-id <draft_id> --attachment-id <attachment_id> ```
Send Draft
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/drafts/{draft_id}/send**CLI:** ```bash agentmail inboxes drafts send --inbox-id <inbox_id> --draft-id <draft_id> ```
List Webhooks
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooks**CLI:** ```bash agentmail inboxes webhooks list --inbox-id <inbox_id> ```
Create Webhook
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooksCreate a webhook scoped to this inbox. **CLI:** ```bash agentmail inboxes webhooks create --inbox-id <inbox_id> --url https://example.com/webhook --event-types message.received ```
Get Webhook
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooks/{webhook_id}**CLI:** ```bash agentmail inboxes webhooks get --inbox-id <inbox_id> --webhook-id <webhook_id> ```
Update Webhook
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooks/{webhook_id}**CLI:** ```bash agentmail inboxes webhooks update --inbox-id <inbox_id> --webhook-id <webhook_id> --event-types message.received ```
Delete Webhook
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooks/{webhook_id}**CLI:** ```bash agentmail inboxes webhooks delete --inbox-id <inbox_id> --webhook-id <webhook_id> ```
Get Webhook Headers
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooks/{webhook_id}/headersList the names of custom HTTP headers included with deliveries to this inbox-scoped webhook. Header values are write-only and are never returned.
Update Webhook Headers
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooks/{webhook_id}/headersAtomically set, replace, or remove custom HTTP headers included with deliveries to this inbox-scoped webhook. Header values remain write-only.
List Polling Webhooks
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooks/pollingLists the polling webhooks created through this inbox route. **CLI:** ```bash agentmail inboxes webhooks polling list --inbox-id <inbox_id> ```
Create Polling Webhook
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooks/pollingCreate a polling webhook scoped to this inbox and return the `token` that reads it. **CLI:** ```bash agentmail inboxes webhooks polling create --inbox-id <inbox_id> --client-id my-agent --event-types message.received ```
Get Polling Webhook
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooks/polling/{webhook_id}**CLI:** ```bash agentmail inboxes webhooks polling get --inbox-id <inbox_id> --webhook-id <webhook_id> ```
Delete Polling Webhook
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/webhooks/polling/{webhook_id}**CLI:** ```bash agentmail inboxes webhooks polling delete --inbox-id <inbox_id> --webhook-id <webhook_id> ```
List Entries
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/lists/{direction}/{type}**CLI:** ```bash agentmail inboxes lists list --inbox-id <inbox_id> --direction <direction> --type <type> ```
Create List Entry
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/lists/{direction}/{type}**CLI:** ```bash agentmail inboxes lists create --inbox-id <inbox_id> --direction <direction> --type <type> --entry user@example.com ```
Get List Entry
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/lists/{direction}/{type}/{entry}**CLI:** ```bash agentmail inboxes lists get --inbox-id <inbox_id> --direction <direction> --type <type> --entry <entry> ```
Delete List Entry
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/lists/{direction}/{type}/{entry}**CLI:** ```bash agentmail inboxes lists delete --inbox-id <inbox_id> --direction <direction> --type <type> --entry <entry> ```
Get Forwarding
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/forwardingGet the forwarding this inbox sets. When the inbox sets nothing, `destinations` is `null` and the inbox uses its pod's forwarding, or the organization's when the pod sets none. **CLI:** ```bash agentmail inboxes forwarding get --inbox-id <inbox_id> ```
Update Forwarding
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/forwardingSet the addresses this inbox forwards to. The list replaces the inbox's current one and any pod or organization list for this inbox; lists are never combined. Send an empty list to stop this inbox forwarding even when its pod or the organization forwards. An address that is not verified is saved but receives nothing until it is verified. **CLI:** ```bash agentmail inboxes forwarding update --inbox-id <inbox_id> --destinations ops@example.com ```
Delete Forwarding
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/forwardingRemove this inbox's own forwarding, so the inbox uses its pod's or the organization's forwarding again. Verified addresses stay verified. Returns `not_found` when the inbox sets no forwarding. **CLI:** ```bash agentmail inboxes forwarding delete --inbox-id <inbox_id> ```
Query Events
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/metrics/eventsCounts of email events (sent, delivered, bounced, etc.) over time for the inbox. Defaults to the last 24 hours; `start` must be within the last 90 days, and a future `end` is clamped to now. Omit `period` for individual event counts, or set it to sum counts into buckets of that many seconds. **CLI:** ```bash agentmail inboxes metrics query-events --inbox-id <inbox_id> ```
Query Usage
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/metrics/usageCumulative usage series for the inbox. Each point is the running total of the usage type at that timestamp, not the change within the bucket. Inbox-scoped queries carry `storage_bytes`, `message_count`, and `thread_count`; requested types that don't apply to the scope are ignored. Defaults to the last 24 hours; `start` must be within the last 90 days, and a future `end` is clamped to now. The range divided by `period` must not exceed 1000 buckets.
Query Rates
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/metrics/ratesRolling bounce and complaint rates for the inbox. At each `period` grid point, the bounced (or complained) messages over the preceding `window` divided by the messages sent over the same window, with the send count alongside. Account moderation evaluates the organization-wide rate, so use the organization endpoint to see the number it acts on; the inbox view shows which inboxes contribute. Defaults to the rolling 24-hour rate sampled hourly over the last day; `start` must be within the last 90 days, `window` must be a whole multiple of `period`, and the range plus window divided by `period` must not exceed 1000 buckets. **CLI:** ```bash agentmail inboxes metrics query-rates --inbox-id <inbox_id> ```
List Inbox Events
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/eventsList label change events for an inbox. Returns events in reverse chronological order by default. Use for IMAP UID projection or audit logging. **CLI:** ```bash agentmail inboxes events list --inbox-id <inbox_id> ```
List API Keys
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/api-keys**CLI:** ```bash agentmail inboxes api-keys list --inbox-id <inbox_id> ```
Create API Key
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/api-keys**CLI:** ```bash agentmail inboxes api-keys create --inbox-id <inbox_id> --name "My Key" ```
Update API Key
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/api-keys/{api_key_id}**CLI:** ```bash agentmail inboxes api-keys update --inbox-id <inbox_id> --api-key-id <api_key_id> --name "Renamed" ```
Delete API Key
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/api-keys/{api_key_id}**CLI:** ```bash agentmail inboxes api-keys delete --inbox-id <inbox_id> --api-key-id <api_key_id> ```
List Accounts
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/accountsLists accounts held by the inbox, across all apps. Requires `inbox_read`.
Get Account
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/accounts/{account_id}Returns one account held by the inbox. An account elsewhere is a 404. Requires `inbox_read`.
Get Calendar
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/calendarGets the inbox's calendar. Every inbox has one calendar, so this works before any event is created. Its `etag` (also the `ETag` response header) is the value to send in `If-Match` to make an update conditional. Requires the `calendar_read` permission. Calendar is available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`), which returns `403`.
Update Calendar
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/calendarUpdates the calendar's default time zone. Existing events keep their own `timezone`; only events created later without a `timezone` use the new default. Requires the `calendar_update` permission. To make the update conditional, send the calendar's current `etag` in `If-Match`: a stale value returns `412`. Without `If-Match` the update applies to the calendar as it is. Calendar is available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`), which returns `403`.
List Events
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/calendar/eventsLists the events stored on the calendar: one item per one-off or recurring event, plus one item for each edited date of a recurring event (as that dated event, with `is_exception: true`). Ordered by most recently updated, and cancelled events are included. Use it to sync or manage what you created. To see what is on the calendar in a time window, use Get Agenda. The list is always read in the region that serves the request, so it can trail a change made moments earlier by a few seconds. Requires the `calendar_event_read` permission. Calendar is available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`), which returns `403`.
Create Event
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/calendar/eventsCreates a one-off or recurring event on the inbox's calendar. Times are wall-clock values in `timezone` (the calendar's default time zone if omitted); the response also gives each boundary as a UTC instant in `start_at` and `end_at`. `calendar.event.created` is sent once the event is stored, then `calendar.event.starting` and `calendar.event.ending` as each date begins and ends. With `send_invites: true` the inbox also emails an invitation to every attendee. Pass `client_id` to make retries safe: repeating the request with the same `client_id` and body returns the original event with status `200` instead of `201`, for as long as the event exists. With `send_invites: true`, each attendee counts as one send against the organization, pod and inbox send limits, charged before the event is stored. An over-limit request returns `429` `rate_limit_exceeded` and creates nothing. A replay of an earlier create is not charged again. The event's `etag` is the value to send in `If-Match` to make a later update or delete conditional. Requires the `calendar_event_create` permission. Calendar is available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`), which returns `403`.
Get Agenda
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/calendar/agendaLists every date on the calendar in a time window, ordered by start time: one-off events, and recurring events expanded into their individual dates, with cancelled dates left out. Use it to answer "what is on the calendar". The window defaults to now through 90 days from now and can be at most 366 days. Items omit `description`, `metadata` and `attendees`; get an event by ID for the full object. An item the inbox is invited to still carries `response_status`, so `needs_action` marks an invitation waiting for a reply. Dates of recurring events appear only up to about 90 days from now; use List Event Instances for a recurring event's later dates. While a recurring event's dates are being regenerated after a schedule change, which takes a few seconds, the agenda can briefly leave out some of them; dates that have already started or ended stay as they ran. The agenda is read in the region that serves the request, so it can trail a change made moments earlier by a few seconds. Pass `consistency=primary` to read your own change right away. Requires the `calendar_event_read` permission. Calendar is available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`), which returns `403`.
Get Event
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/calendar/events/{event_id}Gets an event by its UUID, or one date of a recurring event by its dated ID (`<uuid>_<slot>`). A dated ID returns the date as it currently stands, including any edit to it, with `kind: instance`. The response's `etag` (also the `ETag` header) is the value to send in `If-Match` to make an update, delete or response to this event or date conditional. Treat it as opaque. Reads can trail a change made moments earlier by a few seconds; pass `consistency=primary` to read the latest state of an event or a date. A date that has already started or ended reads back as it ran, even if a later change to the series no longer produces it. Requires the `calendar_event_read` permission. Calendar is available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`), which returns `403`.
Update Event
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/calendar/events/{event_id}Updates an event. Send only the fields to change. To make the update conditional, send the event's current `etag` in `If-Match`: a stale value returns `412`. Without `If-Match` the update applies to the event as it is; a change that lands while it runs returns `409` `race_condition`, so retry. Send `If-Match` when replacing `attendees`, so you don't overwrite a response that arrived in the meantime. - **One-off or series UUID:** changes the event itself. For a series, the change applies to every date that has not been edited individually. - **Dated ID (`<uuid>_<slot>`):** changes one date (`mode=single`, the default) or that date and every later date (`mode=future`). `all_day`, `timezone` and `recurrence` cannot be sent for a dated ID. Once a date has started, its start can no longer change (409 `event_already_started`), but its end and status can; for a one-off or series UUID, send the unchanged `start` with the new `end`. Once it has ended, only `title`, `description`, `location`, `metadata` and `attendees` can change. During the few seconds a date is starting, schedule changes return 409 `event_starting`; retry shortly. Sends `calendar.event.updated`. With `send_invites: true` the organizer inbox also emails the updated invitation to every attendee. Requires the `calendar_event_update` permission. Emailing attendees counts one send per attendee against the organization, pod and inbox send limits, charged before the change is saved; an over-limit request returns `429` `rate_limit_exceeded` and changes nothing. Calendar is available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`), which returns `403`.
Delete Event
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/calendar/events/{event_id}Deletes an event, or cancels dates of a recurring event. - **One-off or series UUID:** deletes the event and every date of it. The event disappears from reads immediately and is removed in the background; the response is `202` with a `deletion_id`. A retry returns the same `deletion_id` while removal runs (send the same `Idempotency-Key`, or none and the same `send_invites`); once it has finished, the event no longer exists and a retry returns `404`. No `calendar.event.starting` or `calendar.event.ending` webhook is sent for the event after the delete is accepted. - **Dated ID (`<uuid>_<slot>`):** cancels that date (`mode=single`, the default) or that date and every later date (`mode=future`). Returns `202` with the cancelled date. A `mode=future` delete from the first date deletes the whole series and returns a `deletion_id` instead. A date that is already running still gets its `calendar.event.ending`. Deleting a one-off or series event sends `calendar.event.deleted`. Cancelling dates sends `calendar.event.updated` with the cancelled date. With `send_invites=true` the organizer inbox also emails a cancellation to every attendee. Requires the `calendar_event_delete` permission. To make the delete conditional, send the current `etag` in `If-Match`. Emailing cancellations counts one send per attendee against the organization, pod and inbox send limits, charged before the delete; an over-limit request returns `429` `rate_limit_exceeded` and deletes nothing. Calendar is available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`), which returns `403`.
List Event Instances
$MeteredGET https://docs.agentmail.to/v0/inboxes/{inbox_id}/calendar/events/{event_id}/instancesLists the dates of one recurring event in a time window, in start order, with each date's edits applied. Dates are computed from the rule, so this works for any window up to 366 days, including dates far in the future. Cancelled dates are left out. The window defaults to now through 90 days from now. Items omit `description`, `metadata` and `attendees`; get a date by its ID for the full object. Like other reads, the list can trail a change made moments earlier by a few seconds; pass `consistency=primary` to read your own change right away. Requires the `calendar_event_read` permission. Calendar is available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`), which returns `403`.
Respond to Event
$MeteredPOST https://docs.agentmail.to/v0/inboxes/{inbox_id}/calendar/events/{event_id}/respondAccepts, declines or tentatively accepts an invitation the inbox received by email. Pass the event's UUID to respond for every date, or a dated ID to respond for one date only. Only works on `email` events where the inbox is an attendee; anything else returns 409 `calendar_response_invalid`. Updates the inbox's attendee entry and sends `calendar.event.responded`. With `send_reply` (default `true`) the inbox emails the response to the organizer. Requires the `calendar_event_update` permission. To make the response conditional, send the current `etag` in `If-Match`. A reply email counts as one send against the organization, pod and inbox send limits, charged before the response is saved; an over-limit request returns `429` `rate_limit_exceeded` and changes nothing. Calendar is available in US production (`api.agentmail.to`) but not yet in EU production (`api.agentmail.eu`), which returns `403`.
List Threads
$MeteredGET https://docs.agentmail.to/v0/threadsLists threads, most recent first. Pass `senders`, `recipients`, or `subject` to filter by substring. Filtered requests are served by search, which caps `limit` at 100. For relevance-ranked full-text search across senders, recipients, subject, and message body, use `Search Threads`. **CLI:** ```bash agentmail threads list ```
Search Threads
$MeteredGET https://docs.agentmail.to/v0/threads/searchFull-text search across threads in the organization, ranked by relevance. The query is matched against senders, recipients, and subject (substring) and the message body (tokenized full text). Spam, trash, blocked, and unauthenticated threads are always excluded. `limit` cannot exceed 100.
Get Thread
$MeteredGET https://docs.agentmail.to/v0/threads/{thread_id}**CLI:** ```bash agentmail threads get --thread-id <thread_id> ```
Update Thread
$MeteredGET https://docs.agentmail.to/v0/threads/{thread_id}Updates thread labels. Cannot add or remove system labels (sent, received, bounced, etc.). Rejects requests with a `422` for threads with 100 or more messages.
Delete Thread
$MeteredGET https://docs.agentmail.to/v0/threads/{thread_id}Permanently deletes a thread and all of its messages. **CLI:** ```bash agentmail threads delete --thread-id <thread_id> ```
Get Attachment
$MeteredGET https://docs.agentmail.to/v0/threads/{thread_id}/attachments/{attachment_id}**CLI:** ```bash agentmail threads get-attachment --thread-id <thread_id> --attachment-id <attachment_id> ```
List Drafts
$MeteredGET https://docs.agentmail.to/v0/drafts**CLI:** ```bash agentmail drafts list ```
Get Draft
$MeteredGET https://docs.agentmail.to/v0/drafts/{draft_id}**CLI:** ```bash agentmail drafts get --draft-id <draft_id> ```
Get Attachment
$MeteredGET https://docs.agentmail.to/v0/drafts/{draft_id}/attachments/{attachment_id}**CLI:** ```bash agentmail drafts get-attachment --draft-id <draft_id> --attachment-id <attachment_id> ```
List Webhooks
$MeteredGET https://docs.agentmail.to/v0/webhooks**CLI:** ```bash agentmail webhooks list ```
Create Webhook
$MeteredPOST https://docs.agentmail.to/v0/webhooks**CLI:** ```bash agentmail webhooks create --url https://example.com/webhook --event-types message.received ```
Get Webhook
$MeteredGET https://docs.agentmail.to/v0/webhooks/{webhook_id}**CLI:** ```bash agentmail webhooks get --webhook-id <webhook_id> ```
Update Webhook
$MeteredGET https://docs.agentmail.to/v0/webhooks/{webhook_id}Update inbox or pod subscriptions, or replace the webhook's `event_types` in full when you pass a non-empty `event_types` array (see request field docs). Inbox and pod changes use add/remove lists. **CLI:** ```bash agentmail webhooks update --webhook-id <webhook_id> --add-inbox-ids <inbox_id> ```
Delete Webhook
$MeteredGET https://docs.agentmail.to/v0/webhooks/{webhook_id}**CLI:** ```bash agentmail webhooks delete --webhook-id <webhook_id> ```
Get Webhook Headers
$MeteredGET https://docs.agentmail.to/v0/webhooks/{webhook_id}/headersList the names of custom HTTP headers included with deliveries to this webhook. Header values are write-only and are never returned.
Update Webhook Headers
$MeteredGET https://docs.agentmail.to/v0/webhooks/{webhook_id}/headersAtomically set, replace, or remove custom HTTP headers included with deliveries to this webhook. Header values remain write-only.
List Polling Webhooks
$MeteredGET https://docs.agentmail.to/v0/webhooks/pollingLists the polling webhooks created through this route. `page_token` must come from this endpoint; a token from another list endpoint is rejected. **CLI:** ```bash agentmail webhooks polling list ```
Create Polling Webhook
$MeteredPOST https://docs.agentmail.to/v0/webhooks/pollingCreates a subscription the agent polls for events, and returns the `token` that reads it. Each organization, pod, and inbox holds at most 10 polling webhooks; a repeat create with the same `client_id` re-issues the token of the existing one instead of counting against that limit. **CLI:** ```bash agentmail webhooks polling create --client-id my-agent --event-types message.received ```
Get Polling Webhook
$MeteredGET https://docs.agentmail.to/v0/webhooks/polling/{webhook_id}The `token` is never returned here: create again with the same `client_id` to get a new one. **CLI:** ```bash agentmail webhooks polling get --webhook-id <webhook_id> ```
Delete Polling Webhook
$MeteredGET https://docs.agentmail.to/v0/webhooks/polling/{webhook_id}Stops delivery and invalidates the subscription's token. **CLI:** ```bash agentmail webhooks polling delete --webhook-id <webhook_id> ```
List Domains
$MeteredGET https://docs.agentmail.to/v0/domains**CLI:** ```bash agentmail domains list ```
Create Domain
$MeteredPOST https://docs.agentmail.to/v0/domains**CLI:** ```bash agentmail domains create --domain example.com ```
Get Domain
$MeteredGET https://docs.agentmail.to/v0/domains/{domain_id}**CLI:** ```bash agentmail domains get --domain-id <domain_id> ```
Update Domain
$MeteredGET https://docs.agentmail.to/v0/domains/{domain_id}**CLI:** ```bash agentmail domains update --domain-id <domain_id> ```
Delete Domain
$MeteredGET https://docs.agentmail.to/v0/domains/{domain_id}**CLI:** ```bash agentmail domains delete --domain-id <domain_id> ```
Get Zone File
$MeteredGET https://docs.agentmail.to/v0/domains/{domain_id}/zone-file**CLI:** ```bash agentmail domains get-zone-file --domain-id <domain_id> ```
Verify Domain
$MeteredPOST https://docs.agentmail.to/v0/domains/{domain_id}/verify**CLI:** ```bash agentmail domains verify --domain-id <domain_id> ```
Get Setup Link
$MeteredGET https://docs.agentmail.to/v0/domains/{domain_id}/setup-linkBuild a one-click DNS setup link for the domain via the Domain Connect standard. When the domain's DNS provider supports Domain Connect and carries the AgentMail template, the response contains a signed URL: opening it lets the domain owner approve the required DNS records at their provider, which writes them automatically — no copy-paste. When the provider does not support it, `supported` is `false` and the domain's `records` should be added manually instead.
List Entries
$MeteredGET https://docs.agentmail.to/v0/lists/{direction}/{type}**CLI:** ```bash agentmail lists list --direction <direction> --type <type> ```
Create List Entry
$MeteredPOST https://docs.agentmail.to/v0/lists/{direction}/{type}**CLI:** ```bash agentmail lists create --direction <direction> --type <type> --entry user@example.com ```
Get List Entry
$MeteredGET https://docs.agentmail.to/v0/lists/{direction}/{type}/{entry}**CLI:** ```bash agentmail lists get --direction <direction> --type <type> --entry <entry> ```
Delete List Entry
$MeteredGET https://docs.agentmail.to/v0/lists/{direction}/{type}/{entry}**CLI:** ```bash agentmail lists delete --direction <direction> --type <type> --entry <entry> ```
Get Forwarding
$MeteredGET https://docs.agentmail.to/v0/forwardingGet the forwarding the organization sets. Pods and inboxes that set no forwarding of their own use this list. Needs an organization-scoped API key. **CLI:** ```bash agentmail forwarding get ```
Update Forwarding
$MeteredGET https://docs.agentmail.to/v0/forwardingSet the addresses the organization forwards to. The list replaces the current one. An address that is not verified is saved but receives nothing until it is verified. Needs an organization-scoped API key in an organization that has completed agent verification. **CLI:** ```bash agentmail forwarding update --destinations ops@example.com --destinations archive@example.com ```
Delete Forwarding
$MeteredGET https://docs.agentmail.to/v0/forwardingRemove the organization's forwarding, so its inboxes stop forwarding unless their pod or the inbox sets its own. Verified addresses stay verified, so adding one again needs no new code. Returns `not_found` when the organization sets no forwarding. **CLI:** ```bash agentmail forwarding delete ```
Start Verification
$MeteredPOST https://docs.agentmail.to/v0/forwarding/verificationsEmail a confirmation code to an address, so it can receive forwarded mail once confirmed. Verification belongs to the organization: once verified, the address can be used at the organization, any pod and any inbox. Starting again replaces any code already sent to the address. Needs an organization- or pod-scoped API key in an organization that has completed agent verification. **CLI:** ```bash agentmail forwarding start-verification --destination ops@example.com ```
Confirm Verification
$MeteredPOST https://docs.agentmail.to/v0/forwarding/verifications/confirmSubmit the code emailed by Start Verification to verify the address. A code allows 10 wrong attempts, then stops working even with the right code, and Start Verification sends a new one. Needs an organization- or pod-scoped API key in an organization that has completed agent verification. **CLI:** ```bash agentmail forwarding confirm-verification --destination ops@example.com --code 7KQ2M-XW9PD ```
Query Events
$MeteredGET https://docs.agentmail.to/v0/metrics/eventsCounts of email events (sent, delivered, bounced, etc.) over time for the organization. Defaults to the last 24 hours; `start` must be within the last 90 days, and a future `end` is clamped to now. Omit `period` for individual event counts, or set it to sum counts into buckets of that many seconds. **CLI:** ```bash agentmail metrics query-events ```
Query Usage
$MeteredGET https://docs.agentmail.to/v0/metrics/usageCumulative usage series for the organization. Each point is the running total of the usage type at that timestamp, not the change within the bucket. Defaults to the last 24 hours; `start` must be within the last 90 days, and a future `end` is clamped to now. The range divided by `period` must not exceed 1000 buckets.
Query Rates
$MeteredGET https://docs.agentmail.to/v0/metrics/ratesRolling bounce and complaint rates for the organization. At each `period` grid point, the bounced (or complained) messages over the preceding `window` divided by the messages sent over the same window, with the send count alongside so you can see the volume behind it. AgentMail weighs bounce and complaint signals when deciding whether to suspend an account's sending, so keep both rates low. Defaults to the rolling 24-hour rate sampled hourly over the last day; `start` must be within the last 90 days, `window` must be a whole multiple of `period`, and the range plus window divided by `period` must not exceed 1000 buckets. **CLI:** ```bash agentmail metrics query-rates ```
List API Keys
$MeteredGET https://docs.agentmail.to/v0/api-keysLists every credential, newest first. Filter one family with `type`. Page to token exhaustion: a page can be empty and still carry a `next_page_token`. **CLI:** ```bash agentmail api-keys list ```
Create API Key
$MeteredPOST https://docs.agentmail.to/v0/api-keysCreates a bearer key, or registers a public key when the body carries `public_key`. The route selects the scope. Bearer secrets are returned once. **CLI:** ```bash agentmail api-keys create --name "My Key" ```
Get API Key
$MeteredGET https://docs.agentmail.to/v0/api-keys/{api_key_id}Returns one credential of any family. Public keys also resolve by `client_id`. Poll a sign-in key until `status` is `active`.
Update API Key
$MeteredGET https://docs.agentmail.to/v0/api-keys/{api_key_id}Renames a credential or changes its permissions. Public keys also resolve by `client_id`; a sign-in key accepts only `app_connect` and `app_share_owner`.
Delete API Key
$MeteredGET https://docs.agentmail.to/v0/api-keys/{api_key_id}Deletes one credential of any family. A pending sign-in key is cancelled; an active one is revoked. Public keys also resolve by `client_id`. **CLI:** ```bash agentmail api-keys delete --api-key-id <api_key_id> ```
List Apps
$MeteredGET https://docs.agentmail.to/v0/appsLists apps, most popular first.
Search Apps
$MeteredGET https://docs.agentmail.to/v0/apps/searchSearches apps by name prefix.
Get App
$MeteredGET https://docs.agentmail.to/v0/apps/{app_id}Gets one app by ID or slug. A catalog app returns its full entry. A registered app that the catalog does not list returns its ID and name only, without `updated_at`, so anyone holding its ID can still look it up; a slug finds catalog apps only. List Apps and Search Apps show catalog entries only.
List App Accounts
$MeteredGET https://docs.agentmail.to/v0/apps/{app_id}/accountsLists accounts at one app, most recent sign-in first.
Connect App
$MeteredPOST https://docs.agentmail.to/v0/apps/{app_id}/connectStarts signing an inbox in to an app. Returns a single-use `magic_url`, valid for five minutes, to open in the client that will hold the sign-in; the client enrolls as the inbox and continues to the app. An app in the catalog can be named by its `slug`, as in `POST /v0/apps/firecrawl/connect`. A `404` names the missing resource: `App` or `Inbox`. A `403` `AppSignupLimitError` means the app accepts no more sign-ups from your organization; sign in with an inbox that already has an account there.
List Accounts
$MeteredGET https://docs.agentmail.to/v0/accountsLists accounts across all apps, scoped to the API key: an organization key sees every account, a pod key its pod's, an inbox key its inbox's. Requires `inbox_read`.
Get Account
$MeteredGET https://docs.agentmail.to/v0/accounts/{account_id}Returns one account by ID. An account outside the key's scope is a 404. Requires `inbox_read`.
Update Account
$MeteredGET https://docs.agentmail.to/v0/accounts/{account_id}/updateUpdates one account. Set `status` to `disabled` to stop the inbox from signing in at the app again, or to `enabled` to re-enable it. Idempotent: disabling an already disabled account keeps its original `disabled_at`, and enabling an enabled account is a no-op. Find the `account_id` with List Accounts. An account exists only after an inbox's first sign-in at an app, so it cannot be disabled in advance. A disable applies to that inbox at that app whichever sign-in key is used: the app's next authorization ends in `access_denied`, and a code issued earlier is refused with `invalid_grant`. Access tokens already issued stay valid until they expire, and the app's own session is unaffected. Requires `account_update`, which sign-in keys (`type: public_key`) cannot hold, so call this with a bearer API key. An account outside the key's scope is a 404. A 409 means the account changed during the write; read it again and retry.
List Pods
$MeteredGET https://docs.agentmail.to/v0/pods**CLI:** ```bash agentmail pods list ```
Create Pod
$MeteredPOST https://docs.agentmail.to/v0/pods**CLI:** ```bash agentmail pods create --client-id my-pod ```
Get Pod
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}**CLI:** ```bash agentmail pods get --pod-id <pod_id> ```
Delete Pod
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}**CLI:** ```bash agentmail pods delete --pod-id <pod_id> ```
List Inboxes
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/inboxes**CLI:** ```bash agentmail pods inboxes list --pod-id <pod_id> ```
Create Inbox
$MeteredPOST https://docs.agentmail.to/v0/pods/{pod_id}/inboxes**CLI:** ```bash agentmail pods inboxes create --pod-id <pod_id> --username myagent --domain example.com ```
Search Inboxes
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/inboxes/searchSearches inboxes in the pod by address or display name, ranked by relevance. Each word in the query matches the start of a word in the address or display name, so `sup` matches `support@example.com` but `port` does not. An exact address match always ranks first. `limit` cannot exceed 100. A page can be empty and still carry a `next_page_token`; keep paging until the token is absent.
Get Inbox
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/inboxes/{inbox_id}**CLI:** ```bash agentmail pods inboxes get --pod-id <pod_id> --inbox-id <inbox_id> ```
Update Inbox
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/inboxes/{inbox_id}**CLI:** ```bash agentmail pods inboxes update --pod-id <pod_id> --inbox-id <inbox_id> ```
Delete Inbox
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/inboxes/{inbox_id}Deletion is asynchronous. A `202` means it has started. While it runs, requests for this inbox return `409` `resource_deleting`. Poll `GET /v0/pods/{pod_id}/inboxes/{inbox_id}` until it returns `404`, then the address is free. If the inbox still has its own API keys, delete returns `409` `cannot_delete`: revoke those keys first. **CLI:** ```bash agentmail pods inboxes delete --pod-id <pod_id> --inbox-id <inbox_id> ```
List Threads
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/threadsLists threads in the pod, most recent first. Pass `senders`, `recipients`, or `subject` to filter by substring. Filtered requests are served by search, which caps `limit` at 100. For relevance-ranked full-text search, use `Search Threads`. **CLI:** ```bash agentmail pods threads list --pod-id <pod_id> ```
Search Threads
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/threads/searchFull-text search across threads in the pod, ranked by relevance. The query is matched against senders, recipients, and subject (substring) and the message body (tokenized full text). Spam, trash, blocked, and unauthenticated threads are always excluded. `limit` cannot exceed 100.
Get Thread
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/threads/{thread_id}**CLI:** ```bash agentmail pods threads get --pod-id <pod_id> --thread-id <thread_id> ```
Update Thread
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/threads/{thread_id}Updates thread labels. Cannot add or remove system labels (sent, received, bounced, etc.). Rejects requests with a `422` for threads with 100 or more messages.
Delete Thread
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/threads/{thread_id}Permanently deletes a thread and all of its messages. **CLI:** ```bash agentmail pods threads delete --pod-id <pod_id> --thread-id <thread_id> ```
Get Attachment
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/threads/{thread_id}/attachments/{attachment_id}**CLI:** ```bash agentmail pods threads get-attachment --pod-id <pod_id> --thread-id <thread_id> --attachment-id <attachment_id> ```
List Drafts
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/drafts**CLI:** ```bash agentmail pods drafts list --pod-id <pod_id> ```
Get Draft
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/drafts/{draft_id}**CLI:** ```bash agentmail pods drafts get --pod-id <pod_id> --draft-id <draft_id> ```
Get Attachment
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/drafts/{draft_id}/attachments/{attachment_id}**CLI:** ```bash agentmail pods drafts get-attachment --pod-id <pod_id> --draft-id <draft_id> --attachment-id <attachment_id> ```
List Webhooks
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/webhooks**CLI:** ```bash agentmail pods webhooks list --pod-id <pod_id> ```
Create Webhook
$MeteredPOST https://docs.agentmail.to/v0/pods/{pod_id}/webhooksCreate a webhook scoped to this pod. **CLI:** ```bash agentmail pods webhooks create --pod-id <pod_id> --url https://example.com/webhook --event-types message.received ```
Get Webhook
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/webhooks/{webhook_id}**CLI:** ```bash agentmail pods webhooks get --pod-id <pod_id> --webhook-id <webhook_id> ```
Update Webhook
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/webhooks/{webhook_id}**CLI:** ```bash agentmail pods webhooks update --pod-id <pod_id> --webhook-id <webhook_id> --add-inbox-ids <inbox_id> ```
Delete Webhook
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/webhooks/{webhook_id}**CLI:** ```bash agentmail pods webhooks delete --pod-id <pod_id> --webhook-id <webhook_id> ```
Get Webhook Headers
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/webhooks/{webhook_id}/headersList the names of custom HTTP headers included with deliveries to this pod-scoped webhook. Header values are write-only and are never returned.
Update Webhook Headers
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/webhooks/{webhook_id}/headersAtomically set, replace, or remove custom HTTP headers included with deliveries to this pod-scoped webhook. Header values remain write-only.
List Polling Webhooks
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/webhooks/pollingLists the polling webhooks created through this pod route. **CLI:** ```bash agentmail pods webhooks polling list --pod-id <pod_id> ```
Create Polling Webhook
$MeteredPOST https://docs.agentmail.to/v0/pods/{pod_id}/webhooks/pollingCreate a polling webhook scoped to this pod and return the `token` that reads it. **CLI:** ```bash agentmail pods webhooks polling create --pod-id <pod_id> --client-id my-agent --event-types message.received ```
Get Polling Webhook
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/webhooks/polling/{webhook_id}**CLI:** ```bash agentmail pods webhooks polling get --pod-id <pod_id> --webhook-id <webhook_id> ```
Delete Polling Webhook
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/webhooks/polling/{webhook_id}**CLI:** ```bash agentmail pods webhooks polling delete --pod-id <pod_id> --webhook-id <webhook_id> ```
List Domains
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/domains**CLI:** ```bash agentmail pods domains list --pod-id <pod_id> ```
Create Domain
$MeteredPOST https://docs.agentmail.to/v0/pods/{pod_id}/domains**CLI:** ```bash agentmail pods domains create --pod-id <pod_id> --domain example.com ```
Get Domain
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/domains/{domain_id}**CLI:** ```bash agentmail pods domains get --pod-id <pod_id> --domain-id <domain_id> ```
Update Domain
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/domains/{domain_id}**CLI:** ```bash agentmail pods domains update --pod-id <pod_id> --domain-id <domain_id> ```
Delete Domain
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/domains/{domain_id}**CLI:** ```bash agentmail pods domains delete --pod-id <pod_id> --domain-id <domain_id> ```
Get Zone File
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/domains/{domain_id}/zone-file**CLI:** ```bash agentmail pods domains get-zone-file --pod-id <pod_id> --domain-id <domain_id> ```
Verify Domain
$MeteredPOST https://docs.agentmail.to/v0/pods/{pod_id}/domains/{domain_id}/verify**CLI:** ```bash agentmail pods domains verify --pod-id <pod_id> --domain-id <domain_id> ```
List Entries
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/lists/{direction}/{type}**CLI:** ```bash agentmail pods lists list --pod-id <pod_id> --direction <direction> --type <type> ```
Create List Entry
$MeteredPOST https://docs.agentmail.to/v0/pods/{pod_id}/lists/{direction}/{type}**CLI:** ```bash agentmail pods lists create --pod-id <pod_id> --direction <direction> --type <type> --entry user@example.com ```
Get List Entry
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/lists/{direction}/{type}/{entry}**CLI:** ```bash agentmail pods lists get --pod-id <pod_id> --direction <direction> --type <type> --entry <entry> ```
Delete List Entry
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/lists/{direction}/{type}/{entry}**CLI:** ```bash agentmail pods lists delete --pod-id <pod_id> --direction <direction> --type <type> --entry <entry> ```
Get Forwarding
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/forwardingGet the forwarding this pod sets. Its inboxes that set no forwarding of their own use this list. When the pod sets nothing, `destinations` is `null` and the pod uses the organization's forwarding. **CLI:** ```bash agentmail pods forwarding get --pod-id <pod_id> ```
Update Forwarding
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/forwardingSet the addresses this pod forwards to. The list replaces the pod's current one and the organization's list for this pod; lists are never combined. Send an empty list to stop forwarding in this pod even when the organization forwards. An address that is not verified is saved but receives nothing until it is verified. **CLI:** ```bash agentmail pods forwarding update --pod-id <pod_id> --destinations ops@example.com ```
Delete Forwarding
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/forwardingRemove this pod's own forwarding, so the pod uses the organization's forwarding again. Verified addresses stay verified. Returns `not_found` when the pod sets no forwarding. **CLI:** ```bash agentmail pods forwarding delete --pod-id <pod_id> ```
Query Events
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/metrics/eventsCounts of email events (sent, delivered, bounced, etc.) over time for the pod. Defaults to the last 24 hours; `start` must be within the last 90 days, and a future `end` is clamped to now. Omit `period` for individual event counts, or set it to sum counts into buckets of that many seconds. **CLI:** ```bash agentmail pods metrics query-events --pod-id <pod_id> ```
Query Usage
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/metrics/usageCumulative usage series for the pod. Each point is the running total of the usage type at that timestamp, not the change within the bucket. Pod-scoped queries carry every usage type except `pod_count`; requested types that don't apply to the scope are ignored. Defaults to the last 24 hours; `start` must be within the last 90 days, and a future `end` is clamped to now. The range divided by `period` must not exceed 1000 buckets.
Query Rates
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/metrics/ratesRolling bounce and complaint rates for the pod. At each `period` grid point, the bounced (or complained) messages over the preceding `window` divided by the messages sent over the same window, with the send count alongside. Account moderation evaluates the organization-wide rate, so use the organization endpoint to see the number it acts on; the pod view shows which pods contribute. Defaults to the rolling 24-hour rate sampled hourly over the last day; `start` must be within the last 90 days, `window` must be a whole multiple of `period`, and the range plus window divided by `period` must not exceed 1000 buckets. **CLI:** ```bash agentmail pods metrics query-rates --pod-id <pod_id> ```
List API Keys
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/api-keys**CLI:** ```bash agentmail pods api-keys list --pod-id <pod_id> ```
Create API Key
$MeteredPOST https://docs.agentmail.to/v0/pods/{pod_id}/api-keys**CLI:** ```bash agentmail pods api-keys create --pod-id <pod_id> --name "My Key" ```
Update API Key
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/api-keys/{api_key_id}**CLI:** ```bash agentmail pods api-keys update --pod-id <pod_id> --api-key-id <api_key_id> --name "Renamed" ```
Delete API Key
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/api-keys/{api_key_id}**CLI:** ```bash agentmail pods api-keys delete --pod-id <pod_id> --api-key-id <api_key_id> ```
List Accounts
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/accountsLists accounts held by inboxes in the pod, across all apps. Requires `inbox_read`.
Get Account
$MeteredGET https://docs.agentmail.to/v0/pods/{pod_id}/accounts/{account_id}Returns one account held by inboxes in the pod. An account elsewhere is a 404. Requires `inbox_read`.
Get Organization
$MeteredGET https://docs.agentmail.to/v0/organizationsReturns the organization for the authenticated API key (usage limits, counts, and billing metadata). **CLI:** ```bash agentmail organizations get ```
Get Labs
$MeteredGET https://docs.agentmail.to/v0/organizations/labsReturns whether the organization is in AgentMail Labs, which turns on features that are still in preview, such as [Agent Armor](https://docs.agentmail.to/agent-armor). Requires an organization-scoped API key. **CLI:** ```bash agentmail organizations get-labs ```
Join Labs
$MeteredPOST https://docs.agentmail.to/v0/organizations/labsJoins AgentMail Labs for the whole organization, which turns on every feature in Labs for every inbox. Joining again has no effect. There is no leave on the API; an organization admin can leave in the console under [Settings, then Labs](https://console.agentmail.to/dashboard/settings/labs). Join only when your organization has decided to. Get Labs reads the same for an organization that never joined and one whose admin left Labs on purpose, so don't join just because `enabled` is `false`. Requires an organization-scoped API key with no permissions restriction, and a verified organization. API keys see the change within five minutes. Where Labs isn't offered (`available` is `false` on Get Labs), joining returns `403`. **CLI:** ```bash agentmail organizations join-labs ```
Who Am I
$MeteredGET https://docs.agentmail.to/v0/auth/meReturns the identity and scope of the authenticated credential. Useful when a client holds a pod-scoped or inbox-scoped API key and needs to discover the parent organization, pod, or inbox without prior knowledge. **CLI:** ```bash agentmail auth me ```
Checks
reachable
valid
2026-11-23T06:32:55.033Z
No settlement evidence found in chain signals.
Gateway routing
Score ≥70/100 — Cleared attestation pass. Route via Gateway before pay.
Claim to manage this card — or go straight to Cleared attestation ($49/mo).
Claim listing