Developers
API reference
Base URL https://api.futuremail.dev. Authenticate with Authorization: Bearer fm_live_… (create keys in Settings → API keys, or with fm keys create). Request and response bodies are JSON; errors look like { "error": { "code", "message", "fix", "docs" } }, and lists are { "data": [...], "nextCursor" } (pass nextCursor as cursor).
Address fields in requests accept "ada@example.com", "Ada <ada@example.com>" or { "address", "name" }, and recipient fields also take an array of them.
Without an active plan (Free or Pro), sending and creating domains, addresses, agents, keys and webhooks return 402 upgrade_required. On Free, adding or sending from a custom (non-sandbox) domain returns 402 upgrade_required too. Rate limit: 10 requests/second per key (429 with Retry-After).
This page is generated from the OpenAPI 3.1 spec at https://api.futuremail.dev/openapi.json: import it into Postman, Insomnia or a client generator. For guides (webhooks, MCP, the CLI, Resend compatibility), see the developer docs.
Account
Who am I
get/v1/mescope: any key
The current organization, plan and usage, and the API key making the request. Call this first to check a key.
curl https://api.futuremail.dev/v1/me \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Me — OK
Turn AI sorting on or off
patch/v1/inbox-aiscope: full
AI sorting puts new mail in lanes and writes a short gist and suggested replies. Paid plans; admins (or a full-access key). When it's off, rules sort the inbox.
Body
| Field | Type | Description |
|---|---|---|
enabledrequired | boolean | |
afterUpgrade | boolean |
curl -X PATCH https://api.futuremail.dev/v1/inbox-ai \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"enabled": true
}'Returns 200 InboxAi — OK Also: 402 upgrade_required: AI sorting needs a paid plan (Pro, Max or Ultra).
Emails
Send an email
post/v1/emailsscope: send · needs an active plan
Send now, or later with scheduledAt. from must be an address on one of your verified domains. To test without sending anything, address it to delivered@test.futuremail.dev (or bounced@, complained@, delayed@): test sends don't count toward your limits.
| Parameter | In | Type | Description |
|---|---|---|---|
Idempotency-Key | header | string | Safe retries: the same key within 24 hours returns the original response instead of sending again (≤256 chars). |
Body
| Field | Type | Description |
|---|---|---|
from | address | An address you own: "me@mydomain.com", "Me <me@mydomain.com>" or { address, name }. Optional when template has a default sender. |
torequired | address | address[] | One recipient or an array (To + Cc + Bcc count toward your plan's recipient caps). |
cc | address | address[] | Copy recipients. |
bcc | address | address[] | Blind-copy recipients. |
replyTo | address | address[] | Reply-To address(es). |
subject | string | Subject line. · default "", max 998 chars |
text | string | Plain-text body. With markdown / app: the fallback for clients without FutureMail (generated from them if omitted). |
html | string | HTML body. With markdown / app: the fallback for clients without FutureMail (generated from them if omitted: rendered Markdown, cards that open the app or diagrams in the browser). |
markdown | string | GitHub-flavored Markdown body. FutureMail renders it (```mermaid blocks as diagrams); other clients get HTML and text rendered from it. |
app | object | An interactive app shown in the message: { html (a complete HTML document; scripts run sandboxed once the reader opens it), title, height (120–2000 px, default 480) }. Other clients get a link that opens it in the browser. |
actions | object[] | Up to 6 one-tap reply buttons: [{ label, reply }] (reply defaults to the label). FutureMail sends the reply in one tap; other clients get mailto: links that draft it. · max 6 |
attachments | AttachmentInput[] | Up to 20 files, 10 MB per message: base64 content, or a public path URL fetched at send time. contentId makes one inline (<img src="cid:…">). · max 20 |
headers | map | Custom headers, e.g. List-Unsubscribe. Headers FutureMail sets itself are rejected. |
inReplyTo | string | Our message id to thread this email onto (sets In-Reply-To/References). |
tags | EmailTag[] | Labels echoed in webhooks and filterable with GET /v1/emails?tag=. Max 50. · max 50 |
scheduledAt | ISO date | Send later (ISO 8601 with offset, up to 30 days ahead). Cancel or reschedule until then. |
template | object | Render a stored template's published version: { id (or alias), variables }. Fields you pass explicitly win. |
curl -X POST https://api.futuremail.dev/v1/emails \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"from": "Example <hello@example.com>",
"to": "ada@example.com",
"subject": "Welcome to Example",
"html": "<p>Hi Ada!</p>",
"tags": [
{
"name": "campaign",
"value": "welcome"
}
]
}'Returns 201 Message — The email, queued (or scheduled). Also: 409 idempotency_key_reused / idempotency_request_in_progress. 429 Rate limit or plan recipient cap reached.
Send up to 100 emails
post/v1/emails/batchscope: send · needs an active plan
Validated all-or-nothing: if any email is invalid nothing is sent and the error names it (3: to: …). Results are in input order.
| Parameter | In | Type | Description |
|---|---|---|---|
Idempotency-Key | header | string | Safe retries: the same key within 24 hours returns the original response instead of sending again (≤256 chars). |
Body — an array (1–100) of the email object below
| Field | Type | Description |
|---|---|---|
from | address | An address you own: "me@mydomain.com", "Me <me@mydomain.com>" or { address, name }. Optional when template has a default sender. |
torequired | address | address[] | One recipient or an array (To + Cc + Bcc count toward your plan's recipient caps). |
cc | address | address[] | Copy recipients. |
bcc | address | address[] | Blind-copy recipients. |
replyTo | address | address[] | Reply-To address(es). |
subject | string | Subject line. · default "", max 998 chars |
text | string | Plain-text body. With markdown / app: the fallback for clients without FutureMail (generated from them if omitted). |
html | string | HTML body. With markdown / app: the fallback for clients without FutureMail (generated from them if omitted: rendered Markdown, cards that open the app or diagrams in the browser). |
markdown | string | GitHub-flavored Markdown body. FutureMail renders it (```mermaid blocks as diagrams); other clients get HTML and text rendered from it. |
app | object | An interactive app shown in the message: { html (a complete HTML document; scripts run sandboxed once the reader opens it), title, height (120–2000 px, default 480) }. Other clients get a link that opens it in the browser. |
actions | object[] | Up to 6 one-tap reply buttons: [{ label, reply }] (reply defaults to the label). FutureMail sends the reply in one tap; other clients get mailto: links that draft it. · max 6 |
attachments | AttachmentInput[] | Up to 20 files, 10 MB per message: base64 content, or a public path URL fetched at send time. contentId makes one inline (<img src="cid:…">). · max 20 |
headers | map | Custom headers, e.g. List-Unsubscribe. Headers FutureMail sets itself are rejected. |
inReplyTo | string | Our message id to thread this email onto (sets In-Reply-To/References). |
tags | EmailTag[] | Labels echoed in webhooks and filterable with GET /v1/emails?tag=. Max 50. · max 50 |
scheduledAt | ISO date | Send later (ISO 8601 with offset, up to 30 days ahead). Cancel or reschedule until then. |
template | object | Render a stored template's published version: { id (or alias), variables }. Fields you pass explicitly win. |
curl -X POST https://api.futuremail.dev/v1/emails/batch \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '[
{
"from": "hello@example.com",
"to": "ada@example.com",
"subject": "Hi Ada",
"text": "Hello!"
},
{
"from": "hello@example.com",
"to": "grace@example.com",
"subject": "Hi Grace",
"text": "Hello!"
}
]'Returns 201 a list of Message — The emails, in input order.
List or search emails
get/v1/emailsscope: read
Newest first. q supports Gmail-style search: from: to: subject: has:attachment is:unread in:sent after:2026-09-01 newer_than:7d.
| Parameter | In | Type | Description |
|---|---|---|---|
q | query | string | Search query. |
mailboxId | query | string | Only this mailbox. |
direction | query | "inbound" | "outbound" | inbound or outbound. |
status | query | string | Comma-separated statuses, e.g. bounced,complained. |
tag | query | string | name:value, or name for any value. |
from | query | string | Substring of the sender address or name. |
to | query | string | Substring of a recipient address (To, Cc or Bcc). |
since | query | ISO date | Only emails after this ISO date. |
until | query | ISO date | Only emails before this ISO date. |
unread | query | boolean | Only unread emails. |
templateId | query | string | Only emails sent with this template (id or alias). |
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/emails \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Message — OK
Wait for an inbound email
get/v1/emails/waitscope: read
Long-poll until the next inbound email matching the filters arrives: ideal for sign-up confirmations and one-time codes (extracted.otp). Returns 204 on timeout. On the Free plan, or on a sandbox domain on any plan, a plus-address in to (me+tag@) is 400 plus_addressing_unavailable: that mail is never received.
| Parameter | In | Type | Description |
|---|---|---|---|
from | query | string | Substring of the sender address or name. |
to | query | string | Substring of a recipient address. |
subject | query | string | Substring of the subject. |
mailboxId | query | string | Only this mailbox. |
since | query | ISO date | Also accept emails that arrived since this ISO date (default: now). |
timeout | query | integer | Seconds to wait, up to 300 (default 60). |
curl https://api.futuremail.dev/v1/emails/wait \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Message — The matching email. Also: 204 Nothing arrived before the timeout. 400 plus_addressing_unavailable: to is a plus-address (me+tag@) on a plan without plus-addressing (Free) or on a sandbox domain (no plus-addressing on any plan), so it never receives. address_not_receiving: to (or its untagged form) is an extra sandbox address that doesn't receive: a sandbox has one address on every plan, and only the oldest receives.
Get an email
get/v1/emails/{id}scope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Email id (msg_…). |
curl https://api.futuremail.dev/v1/emails/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Message — OK
Mark read or reschedule
patch/v1/emails/{id}scope: read
scheduledAt moves a scheduled email (needs the send scope); 409 not_scheduled once it's been sent.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Email id (msg_…). |
Body
| Field | Type | Description |
|---|---|---|
read | boolean | Mark read or unread. |
scheduledAt | ISO date | Reschedule a scheduled email (needs the send scope). |
curl -X PATCH https://api.futuremail.dev/v1/emails/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"scheduledAt": "2026-10-09T09:00:00Z"
}'Returns 200 Message — OK
Cancel a scheduled email
post/v1/emails/{id}/cancelscope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Email id (msg_…). |
curl -X POST https://api.futuremail.dev/v1/emails/<id>/cancel \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Message — The email, now canceled. Also: 409 not_scheduled: it was already sent or canceled.
Delivery timeline
get/v1/emails/{id}/eventsscope: read
Oldest first: queued → sent → delivered / bounced / complained / failed, plus opened and clicked when tracking is on.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Email id (msg_…). |
curl https://api.futuremail.dev/v1/emails/<id>/events \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of EmailEvent — OK
Reply
post/v1/emails/{id}/replyscope: send · needs an active plan
Threads correctly (In-Reply-To/References) and quotes the original.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Email id (msg_…). |
Idempotency-Key | header | string | Safe retries: the same key within 24 hours returns the original response instead of sending again (≤256 chars). |
Body
| Field | Type | Description |
|---|---|---|
text | string | Plain-text reply (the original is quoted). |
html | string | HTML reply. |
markdown | string | Markdown reply (rendered for FutureMail; HTML and text fallbacks are generated). Same as when sending. |
app | object | An interactive app, same as when sending. |
actions | object[] | One-tap reply buttons, same as when sending. · max 6 |
replyAll | boolean | Also reply to the original's other recipients. · default false |
from | address | Override the From address (default: the address the original was sent to). |
cc | address | address[] | Extra copy recipients. |
attachments | AttachmentInput[] | Same format as when sending. · max 20 |
curl -X POST https://api.futuremail.dev/v1/emails/<id>/reply \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"text": "Thanks, done!"
}'Returns 201 Message — The reply.
Forward
post/v1/emails/{id}/forwardscope: send · needs an active plan
Attachments are included.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Email id (msg_…). |
Idempotency-Key | header | string | Safe retries: the same key within 24 hours returns the original response instead of sending again (≤256 chars). |
Body
| Field | Type | Description |
|---|---|---|
torequired | address | address[] | Recipient(s). |
text | string | Note above the forwarded message. |
from | address | Override the From address. |
curl -X POST https://api.futuremail.dev/v1/emails/<id>/forward \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"to": "team@example.com",
"text": "FYI"
}'Returns 201 Message — The forwarded email.
An email's interactive app
get/v1/emails/{id}/appscope: read
The rich.app document, served for a sandboxed frame: a CSP sandbox gives it an opaque origin, and browsers only get it inside a frame (Sec-Fetch-Dest: iframe). The app can call window.futuremail.resize(height?) and window.futuremail.reply(text) (the reader confirms the reply).
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Email id (msg_…). |
curl https://api.futuremail.dev/v1/emails/<id>/app \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 text/html — The app's HTML document.
Raw RFC 822 source
get/v1/emails/{id}/rawscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Email id (msg_…). |
curl https://api.futuremail.dev/v1/emails/<id>/raw \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 message/rfc822 — The raw message.
Download an attachment
get/v1/attachments/{id}scope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Attachment id (from Message.attachments). |
download | query | boolean | Send Content-Disposition: attachment. |
curl https://api.futuremail.dev/v1/attachments/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 application/octet-stream — The file, with its content type.
Threads
List conversations
get/v1/threadsscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
folder | query | "inbox" | "starred" | "sent" | "drafts" | "all" | "spam" | "trash" | Folder (default inbox). |
mailboxId | query | string | Only this mailbox. |
domain | query | string | Only conversations received on (delivered to, or in To/Cc) or sent from an address on this domain. |
address | query | string | Only conversations received on (delivered to, or in To/Cc) or sent from this address. Takes precedence over domain. |
q | query | string | Search query (same syntax as emails). |
lane | query | "attention" | "interest" | "notifications" | "reading" | "handled" | "noise" | "spam" | Only this lane (inbox folder; spam lists the Spam folder). |
pinned | query | boolean | true: only pinned conversations; false: leave pinned ones out. |
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/threads \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Thread — OK
Count conversations per lane
get/v1/threads/lane-countsscope: read
Threads (and threads with unread mail) in each lane of the inbox, scoped like listing threads.
| Parameter | In | Type | Description |
|---|---|---|---|
mailboxId | query | string | Only this mailbox. |
domain | query | string | Only conversations on this domain. |
address | query | string | Only conversations on this address. Takes precedence over domain. |
curl https://api.futuremail.dev/v1/threads/lane-counts \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 LaneCounts — OK
Get a thread with its messages
get/v1/threads/{id}scope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Thread id (thr_…). |
curl https://api.futuremail.dev/v1/threads/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 ThreadWithMessages — OK
Archive, star, mark read or move to a lane
patch/v1/threads/{id}scope: read
Moving to a lane (lane) also teaches the inbox: later mail from the same sender lands in that lane.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Thread id. |
Body
| Field | Type | Description |
|---|---|---|
status | "inbox" | "archived" | "trash" | "spam" | Move the thread. |
starred | boolean | Star or unstar. |
pinned | boolean | Pin to (or unpin from) the top of the inbox. |
read | boolean | Mark every message read or unread. |
lane | "attention" | "interest" | "notifications" | "reading" | "handled" | "noise" | "spam" |
curl -X PATCH https://api.futuremail.dev/v1/threads/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"status": "archived"
}'Returns 200 Thread — OK
Update many threads
post/v1/threads/batchscope: read
Body
| Field | Type | Description |
|---|---|---|
status | "inbox" | "archived" | "trash" | "spam" | |
starred | boolean | |
pinned | boolean | |
read | boolean | |
lane | "attention" | "interest" | "notifications" | "reading" | "handled" | "noise" | "spam" | |
idsrequired | string[] | Up to 500 thread ids. · max 500 |
curl -X POST https://api.futuremail.dev/v1/threads/batch \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"ids": [
"thr_1",
"thr_2"
],
"read": true
}'Returns 200 a list of Thread — OK
Delete a thread permanently
delete/v1/threads/{id}scope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Thread id. |
curl -X DELETE https://api.futuremail.dev/v1/threads/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Deleted — Deleted.
Domains
List domains
get/v1/domainsscope: any key
| Parameter | In | Type | Description |
|---|---|---|---|
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/domains \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Domain — OK
Add a domain
post/v1/domainsscope: full · needs an active plan
Returns the DNS records to create (DKIM, MX, SPF, DMARC, MAIL FROM). Then call verify. A name under the sandbox domain (Me.features.sandboxDomain, e.g. myapp.fm-sandbox.dev) creates the org's one sandbox domain instead: verified at once, no DNS, the only kind of domain on the Free plan.
Body
| Field | Type | Description |
|---|---|---|
namerequired | string | The domain, e.g. example.com. The response lists the DNS records to create. |
curl -X POST https://api.futuremail.dev/v1/domains \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "example.com"
}'Returns 201 Domain — Created. Also: 402 upgrade_required: the Free plan has no custom domains, or the plan's custom-domain cap is reached (Pro 5, Max 20, Ultra 50; the sandbox doesn't count). 403 domain_limit_reached: the per-organization safety cap on custom domains (MAX_DOMAINS_PER_ORG). 409 The domain is already in use.
Suggest a sandbox name
get/v1/domains/sandbox/suggestionscope: any key
A free sandbox domain name based on your team, email or name (e.g. acme.fm-sandbox.dev), to pass to createDomain. name is null when sandboxes aren't offered.
curl https://api.futuremail.dev/v1/domains/sandbox/suggestion \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 SandboxSuggestion — OK
Check a sandbox name
get/v1/domains/sandbox/availabilityscope: any key
Whether you can take this sandbox name: well-formed, not reserved and not taken.
| Parameter | In | Type | Description |
|---|---|---|---|
namerequired | query | string | The name, e.g. myapp or myapp.fm-sandbox.dev. |
curl https://api.futuremail.dev/v1/domains/sandbox/availability \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 SandboxAvailability — OK
Get a domain
get/v1/domains/{id}scope: any key
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Domain id or name. |
curl https://api.futuremail.dev/v1/domains/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Domain — OK
Re-check DNS
post/v1/domains/{id}/verifyscope: full
Looks up every record now. sendingEnabled turns on when DKIM verifies, receivingEnabled when MX points at FutureMail.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Domain id or name. |
curl -X POST https://api.futuremail.dev/v1/domains/<id>/verify \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Domain — OK
Domain settings
patch/v1/domains/{id}scope: full
Catch-all, custom MAIL FROM, TLS policy and open/click tracking.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Domain id or name. |
Body
| Field | Type | Description |
|---|---|---|
catchAllMailboxId | string | null | Mailbox that receives mail for unknown addresses on this domain (null turns catch-all off). Paid plans only. |
mailFromSubdomain | string | Custom MAIL FROM (bounce) subdomain, default "bounce". Changing it means new MX + SPF records. · max 100 chars |
tlsPolicy | "opportunistic" | "require" | "require" only delivers over TLS; "opportunistic" (default) uses TLS when available. |
openTracking | boolean | Add a tracking pixel to outgoing HTML (email.opened). |
clickTracking | boolean | Rewrite links through the tracker (email.clicked). |
trackingSubdomain | string | null | Custom tracking host label, e.g. "links" → links.example.com (null removes it). |
curl -X PATCH https://api.futuremail.dev/v1/domains/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"clickTracking": true,
"openTracking": true
}'Returns 200 Domain — OK
Remove a domain
delete/v1/domains/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Domain id or name. |
curl -X DELETE https://api.futuremail.dev/v1/domains/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Deleted — Deleted. Also: 400 sandbox_address_locked: this sandbox holds the account's sandbox address.
Addresses
List addresses
get/v1/addressesscope: any key
| Parameter | In | Type | Description |
|---|---|---|---|
mailboxId | query | string | Only this mailbox. |
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/addresses \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Address — OK
Check an address
get/v1/addresses/availabilityscope: any key
Whether you can create this address (its domain must be one of yours).
| Parameter | In | Type | Description |
|---|---|---|---|
addressrequired | query | string | Full address, e.g. hello@example.com. |
curl https://api.futuremail.dev/v1/addresses/availability \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 AddressAvailability — OK
Create an address
post/v1/addressesscope: full · needs an active plan
Each address delivers into one mailbox. Every plan caps addresses across all domains (Billing.limits.addresses): Free 1 (and 3 new ones per 30 days, deleted ones count), Pro 20, Max 50, Ultra 100. Beyond that: 402 upgrade_required.
Body
| Field | Type | Description |
|---|---|---|
addressrequired | string | Full address on one of your domains, e.g. hello@example.com. |
mailboxId | string | Mailbox to deliver to (default: your personal mailbox). |
displayName | string | null | Name shown in From. |
curl -X POST https://api.futuremail.dev/v1/addresses \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"address": "support@example.com",
"displayName": "Example Support"
}'Returns 201 Address — Created. Also: 400 sandbox_address_limit: the sandbox already has its one address (every plan); put more on your own domain. 402 upgrade_required: the plan's address cap is reached (or Free's 3 new addresses per 30 days).
Update an address
patch/v1/addresses/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Address id or the address itself. |
Body
| Field | Type | Description |
|---|---|---|
mailboxId | string | Move the address to another mailbox. |
displayName | string | null | Name shown in From. |
curl -X PATCH https://api.futuremail.dev/v1/addresses/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"displayName": "Example Help"
}'Returns 200 Address — OK
Delete an address
delete/v1/addresses/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Address id or the address itself. |
curl -X DELETE https://api.futuremail.dev/v1/addresses/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Deleted — Deleted. Also: 400 sandbox_address_locked: the account's sandbox address is permanent.
Mailboxes & agents
List mailboxes
get/v1/mailboxesscope: any key
| Parameter | In | Type | Description |
|---|---|---|---|
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/mailboxes \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Mailbox — OK
Create a mailbox
post/v1/mailboxesscope: full · needs an active plan
Body
| Field | Type | Description |
|---|---|---|
namerequired | string | Mailbox name. · max 60 chars |
kind | "personal" | "agent" | personal or agent. · default "personal" |
description | string | null | What it's for. |
color | string | Hex accent color for the web app. |
curl -X POST https://api.futuremail.dev/v1/mailboxes \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Support"
}'Returns 201 Mailbox — Created.
Get a mailbox
get/v1/mailboxes/{id}scope: any key
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Mailbox id (mbx_…). |
curl https://api.futuremail.dev/v1/mailboxes/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Mailbox — OK
Update a mailbox
patch/v1/mailboxes/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Mailbox id. |
Body
| Field | Type | Description |
|---|---|---|
name | string | max 60 chars |
description | string | null | |
color | string | |
signature | string | null | Appended to replies written in the web app. |
primaryAddress | string | Default From address (must belong to this mailbox). |
curl -X PATCH https://api.futuremail.dev/v1/mailboxes/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"primaryAddress": "support@example.com"
}'Returns 200 Mailbox — OK
Delete a mailbox
delete/v1/mailboxes/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Mailbox id. |
curl -X DELETE https://api.futuremail.dev/v1/mailboxes/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Deleted — Deleted. Also: 400 sandbox_address_locked: this mailbox holds the account's sandbox address; move it to another mailbox first.
Provision an agent inbox
post/v1/agentsscope: full · needs an active plan
Creates an agent mailbox, an address and an API key pinned to that mailbox in one call. The key is returned once. The address counts toward the Free plan's one address.
Body
| Field | Type | Description |
|---|---|---|
namerequired | string | Human name, e.g. "Signup bot". · max 60 chars |
address | string | The agent's address on one of your domains. |
description | string | null | What the agent does. |
scopes | ("send" | "read")[] | Scopes of the agent's key (always pinned to its mailbox, so never full). · default ["send","read"] |
channelOnly | boolean | default false |
inboundPolicy | "open" | "connections" | "org" | "allowlist" |
curl -X POST https://api.futuremail.dev/v1/agents \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Signup bot",
"address": "signup-bot@example.com"
}'Returns 201 AgentProvisioned — Created. Also: 400 sandbox_address_limit (the address would be a second one on the sandbox) or no_domain (no verified domain can take it). 402 upgrade_required: the plan's address cap is reached.
Delete an agent
delete/v1/agents/{id}scope: full
Deletes an agent (a mailbox of kind agent) with its addresses, every API key pinned to it, its Agent Channel endpoints, threads, messages and connections. id is the agent's mailbox id or one of its addresses. Needs a full key or a signed-in developer+: an agent's own pinned key can't delete agents. Platform partners delete the agents they provisioned with DELETE /platform/v1/agents/{agentId}.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Agent mailbox id (mbx_…) or one of its addresses. |
curl -X DELETE https://api.futuremail.dev/v1/agents/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 — Deleted. Also: 404 not_found: no agent with that id or address in this organization (regular mailboxes are deleted with DELETE /v1/mailboxes/{id}). 400 sandbox_address_locked: the agent holds the account's permanent sandbox address.
Templates
List templates
get/v1/templatesscope: any key
| Parameter | In | Type | Description |
|---|---|---|---|
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/templates \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Template — OK
Create a template
post/v1/templatesscope: full
Edits change the draft; sends use the last published version.
Body
| Field | Type | Description |
|---|---|---|
namerequired | string | Internal name. · max 100 chars |
alias | string | null | Stable handle to send with, e.g. "welcome". |
subject | string | Subject; may use {{variables}}. · default "", max 998 chars |
html | string | null | HTML body; {{var}} is HTML-escaped, {{{var}}} is raw. |
text | string | null | Plain-text body. |
from | string | null | Default sender for sends that don't pass one. |
replyTo | string[] | Default Reply-To addresses. · max 10 |
variables | object[] | Declared variables: { key, type, fallback }. A missing variable without a fallback is a 422. · max 50 |
publish | boolean | Publish right away so it can be used for sending. · default false |
curl -X POST https://api.futuremail.dev/v1/templates \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Welcome",
"alias": "welcome",
"subject": "Welcome, {{name}}!",
"html": "<p>Hi {{name}}</p>",
"variables": [
{
"key": "name",
"fallback": "there"
}
],
"publish": true
}'Returns 201 Template — Created.
Get a template
get/v1/templates/{id}scope: any key
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Template id or alias. |
curl https://api.futuremail.dev/v1/templates/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Template — OK
Edit the draft
patch/v1/templates/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Template id or alias. |
Body
| Field | Type | Description |
|---|---|---|
name | string | max 100 chars |
alias | string | null | |
subject | string | max 998 chars |
html | string | null | |
text | string | null | |
from | string | null | |
replyTo | string[] | max 10 |
variables | object[] | max 50 |
curl -X PATCH https://api.futuremail.dev/v1/templates/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"subject": "Welcome aboard, {{name}}!"
}'Returns 200 Template — OK
Publish the draft
post/v1/templates/{id}/publishscope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Template id or alias. |
curl -X POST https://api.futuremail.dev/v1/templates/<id>/publish \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Template — OK
Render with variables
post/v1/templates/{id}/renderscope: any key
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Template id or alias. |
Body
| Field | Type | Description |
|---|---|---|
variables | map | Values for the template's variables. · default {} |
draft | boolean | Render the draft instead of the published version. · default false |
curl -X POST https://api.futuremail.dev/v1/templates/<id>/render \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"variables": {
"name": "Ada"
}
}'Returns 200 RenderedTemplate — OK
Delete a template
delete/v1/templates/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Template id or alias. |
curl -X DELETE https://api.futuremail.dev/v1/templates/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Deleted — Deleted.
Suppressions
List suppressed addresses
get/v1/suppressionsscope: read
Addresses your org won't send to: permanent bounces and complaints are added automatically.
| Parameter | In | Type | Description |
|---|---|---|---|
reason | query | "bounce" | "complaint" | "manual" | "unsubscribe" | Only this reason. |
q | query | string | Substring of the address. |
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/suppressions \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Suppression — OK
Suppress addresses
post/v1/suppressionsscope: full
Body
| Field | Type | Description |
|---|---|---|
email | string | One address. · max 320 chars |
emails | string[] | Many addresses (up to 1,000 in total). · max 1000 |
reason | "manual" | "unsubscribe" | manual (default) or unsubscribe. · default "manual" |
details | string | null | Note shown next to the entry. |
curl -X POST https://api.futuremail.dev/v1/suppressions \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"emails": [
"old@example.com"
],
"reason": "unsubscribe"
}'Returns 201 AddSuppressionsResult — Added (200 when every address was already suppressed).
Check addresses
post/v1/suppressions/checkscope: read
Body
| Field | Type | Description |
|---|---|---|
emailsrequired | string[] | Addresses to check (up to 1,000). · max 1000 |
curl -X POST https://api.futuremail.dev/v1/suppressions/check \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"emails": [
"ada@example.com",
"old@example.com"
]
}'Returns 200 CheckSuppressionsResult — OK
Get a suppression
get/v1/suppressions/{email}scope: read
| Parameter | In | Type | Description |
|---|---|---|---|
emailrequired | path | string | The suppressed address. |
curl https://api.futuremail.dev/v1/suppressions/<email> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Suppression — OK
Remove a suppression
delete/v1/suppressions/{email}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
emailrequired | path | string | The suppressed address. |
curl -X DELETE https://api.futuremail.dev/v1/suppressions/<email> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Deleted — Deleted.
API keys
List API keys
get/v1/api-keysscope: full
| Parameter | In | Type | Description |
|---|---|---|---|
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/api-keys \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of ApiKey — OK
Create an API key
post/v1/api-keysscope: full · needs an active plan
The secret is returned once. Restrict keys to a mailbox, a sending domain and/or an expiry.
Body
| Field | Type | Description |
|---|---|---|
namerequired | string | Label for the key. · max 60 chars |
scopes | ("full" | "send" | "read")[] | full, send and/or read. · default ["full"] |
mailboxId | string | null | Restrict the key to one mailbox. |
domainId | string | null | Restrict sending to addresses on one domain. |
expiresAt | ISO date | null | When the key stops working (omit for never). |
curl -X POST https://api.futuremail.dev/v1/api-keys \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "CI",
"scopes": [
"send"
],
"expiresAt": "2027-01-01T00:00:00Z"
}'Returns 201 ApiKeyWithSecret — Created.
Update an API key
patch/v1/api-keys/{id}scope: full
Expiry can't be changed: rotate the key instead.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Key id (key_…). |
Body
| Field | Type | Description |
|---|---|---|
name | string | max 60 chars |
scopes | ("full" | "send" | "read")[] | |
mailboxId | string | null | null removes the mailbox restriction. |
domainId | string | null | null removes the domain restriction. |
curl -X PATCH https://api.futuremail.dev/v1/api-keys/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "CI (deploys)"
}'Returns 200 ApiKey — OK
Revoke an API key
delete/v1/api-keys/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Key id. |
curl -X DELETE https://api.futuremail.dev/v1/api-keys/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Deleted — Deleted.
Webhooks
List webhooks
get/v1/webhooksscope: full
| Parameter | In | Type | Description |
|---|---|---|---|
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/webhooks \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Webhook — OK
Create a webhook
post/v1/webhooksscope: full · needs an active plan
Events are POSTed as { id, type, createdAt, data } with a FutureMail-Signature: t=<unix>,v1=<hex> header, where v1 = HMAC-SHA256(secret, <t>.<raw body>). Non-2xx responses are retried with backoff (8 attempts).
Body
| Field | Type | Description |
|---|---|---|
urlrequired | string | HTTPS endpoint that receives POSTed events. |
events | ("email.received" | "email.scheduled" | "email.sent" | "email.delivery_delayed" | "email.delivered" | "email.bounced" | "email.complained" | "email.failed" | "email.suppressed" | "email.opened" | "email.clicked" | "domain.verified" | "channel.message.received" | "channel.message.delivered" | "channel.message.failed" | "channel.message.held" | "channel.message.released" | "channel.connection.requested" | "channel.connection.accepted" | "channel.endpoint.failing" | "channel.endpoint.disabled" | "channel.endpoint.verified")[] | Event types to deliver (default: email.received). · default ["email.received"] |
curl -X POST https://api.futuremail.dev/v1/webhooks \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://example.com/hooks/mail",
"events": [
"email.received",
"email.bounced"
]
}'Returns 201 Webhook — Created (includes the signing secret, shown once).
Update a webhook
patch/v1/webhooks/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Webhook id. |
Body
| Field | Type | Description |
|---|---|---|
url | string | |
events | ("email.received" | "email.scheduled" | "email.sent" | "email.delivery_delayed" | "email.delivered" | "email.bounced" | "email.complained" | "email.failed" | "email.suppressed" | "email.opened" | "email.clicked" | "domain.verified" | "channel.message.received" | "channel.message.delivered" | "channel.message.failed" | "channel.message.held" | "channel.message.released" | "channel.connection.requested" | "channel.connection.accepted" | "channel.endpoint.failing" | "channel.endpoint.disabled" | "channel.endpoint.verified")[] | |
enabled | boolean | Pause (false) or resume a webhook. Pausing stops pending retries. |
curl -X PATCH https://api.futuremail.dev/v1/webhooks/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"enabled": false
}'Returns 200 Webhook — OK
Delete a webhook
delete/v1/webhooks/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Webhook id. |
curl -X DELETE https://api.futuremail.dev/v1/webhooks/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Deleted — Deleted.
Send a test event
post/v1/webhooks/{id}/testscope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Webhook id. |
curl -X POST https://api.futuremail.dev/v1/webhooks/<id>/test \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 WebhookDelivery — OK
Delivery attempts
get/v1/webhooks/{id}/deliveriesscope: full
Newest first, with status codes, payloads and the next retry. Kept 30 days.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Webhook id. |
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/webhooks/<id>/deliveries \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of WebhookDelivery — OK
Replay a delivery
post/v1/webhooks/{id}/deliveries/{deliveryId}/replayscope: full
Re-sends the exact payload (same event id) now.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Webhook id. |
deliveryIdrequired | path | string | Delivery id. |
curl -X POST https://api.futuremail.dev/v1/webhooks/<id>/deliveries/<deliveryId>/replay \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 WebhookDelivery — OK
Verify a webhook endpoint
post/v1/webhooks/{id}/verifyscope: full
Run challenge verification or confirm test-delivery verification.
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Webhook id. |
Body
| Field | Type | Description |
|---|---|---|
mode | "challenge" | "confirm_test" | default "challenge" |
curl -X POST https://api.futuremail.dev/v1/webhooks/<id>/verify \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"mode": "challenge"
}'Returns 200 EndpointVerifyResult — OK
Mint a single-use 60s SSE stream ticket
post/v1/events/ticketscope: read
Exchange bearer auth or a session cookie for a 60s single-use ticket for browser EventSource (GET /v1/events?ticket=…).
curl -X POST https://api.futuremail.dev/v1/events/ticket \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 201 SseTicketResponse — Ticket minted.
Realtime event stream
get/v1/eventsscope: read
Server-Sent Events for the current org: every webhook event plus thread.updated, as event: <type> / data: <json>. A ready event is sent first. Mailbox-pinned keys only see their mailbox and are rejected in ?key= (use Authorization header or /v1/events/ticket).
curl https://api.futuremail.dev/v1/events \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 text/event-stream — An event stream.
Agent Channel
List your org's agents
get/v1/channel/agentsscope: read
curl https://api.futuremail.dev/v1/channel/agents \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Mailbox — OK
Update an agent's channel profile, policy or scan mode
patch/v1/channel/agents/{id}scope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Agent mailbox id. |
Body
| Field | Type | Description |
|---|---|---|
name | string | max 60 chars |
description | string | null | |
channelOnly | boolean | |
inboundPolicy | "open" | "connections" | "org" | "allowlist" | |
onlyOwnerCanAccept | boolean | |
allowlist | string[] | max 200 |
deliveryPrefs | object | |
scanMode | "default" | "off" | "label" | "hold" | |
paused | boolean | |
publicProfile | object |
curl -X PATCH https://api.futuremail.dev/v1/channel/agents/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"inboundPolicy": "allowlist",
"scanMode": "hold"
}'Returns 200 Mailbox — OK
Get Agent Channel usage and scan credits
get/v1/channel/usagescope: read
curl https://api.futuremail.dev/v1/channel/usage \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 AgentChannelUsage — OK
Update org-wide Agent Channel settings (pause all agents, strict scan mode)
patch/v1/channel/settingsscope: full
Body
| Field | Type | Description |
|---|---|---|
agentsPaused | boolean | |
scanStrict | boolean |
curl -X PATCH https://api.futuremail.dev/v1/channel/settings \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"agentsPaused": false,
"scanStrict": true
}'Returns 200 OrgAgentSettings — OK
Send an Agent Channel message
post/v1/channel/messagesscope: send · needs an active plan
Body
| Field | Type | Description |
|---|---|---|
from | string | |
torequired | string | string[] | |
threadId | string | |
subject | string | default "", max 500 chars |
text | string | |
data | map | |
markdown | string | |
app | object | |
actions | object[] | max 6 |
attachments | AttachmentInput[] | max 20 |
inReplyTo | string | |
expectsReply | boolean | default true |
ttl | integer | 60–2592000 |
metadata | map | |
taskState | "none" | "submitted" | "working" | "input_required" | "completed" | "failed" | "canceled" |
curl -X POST https://api.futuremail.dev/v1/channel/messages \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"to": "grok@acme.com",
"subject": "Deploy #42",
"text": "Ready for review"
}'Returns 201 SendChannelMessageResult — Sent.
List Agent Channel messages
get/v1/channel/messagesscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
mailboxId | query | string | Filter to one agent mailbox. |
threadId | query | string | Filter to one thread. |
unread | query | string | Only unread messages. |
held | query | string | Only held messages (human review). |
curl https://api.futuremail.dev/v1/channel/messages \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of AgentMessage — OK
Pull uncommitted messages for a consumer client_id
get/v1/channel/messages/queuescope: read
| Parameter | In | Type | Description |
|---|---|---|---|
client_idrequired | query | string | Consumer identifier. |
mailboxId | query | string | Agent mailbox id. |
limit | query | string | Batch size (1–100). |
curl https://api.futuremail.dev/v1/channel/messages/queue \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 ChannelQueueBatch — OK
Advance a consumer's commit-queue cursor idempotently
post/v1/channel/messages/commitscope: read
Body
| Field | Type | Description |
|---|---|---|
clientIdrequired | string | max 128 chars |
cursorrequired | string | max 512 chars |
mailboxId | string |
curl -X POST https://api.futuremail.dev/v1/channel/messages/commit \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"clientId": "worker-1",
"cursor": "2026-01-01T00:00:00Z|msg_123"
}'Returns 200 ChannelCommitResult — OK
Long-poll for the next inbound Agent Channel message
get/v1/channel/messages/waitscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
mailboxId | query | string | Agent mailbox id. |
threadId | query | string | Filter to thread. |
from | query | string | Sender substring. |
since | query | string | ISO timestamp. |
timeout | query | string | Seconds (1–300). |
curl https://api.futuremail.dev/v1/channel/messages/wait \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 AgentMessage — OK Also: 204 Timed out with no matching message.
Get an Agent Channel message
get/v1/channel/messages/{id}scope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Message id. |
curl https://api.futuremail.dev/v1/channel/messages/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 AgentMessage — OK
Reply in-thread to an Agent Channel message
post/v1/channel/messages/{id}/replyscope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Message id. |
Body
| Field | Type | Description |
|---|---|---|
text | string | |
data | map | |
markdown | string | |
app | object | |
actions | object[] | max 6 |
attachments | AttachmentInput[] | max 20 |
expectsReply | boolean | default true |
ttl | integer | 60–2592000 |
metadata | map | |
taskState | "none" | "submitted" | "working" | "input_required" | "completed" | "failed" | "canceled" |
curl -X POST https://api.futuremail.dev/v1/channel/messages/<id>/reply \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"text": "Looks good, shipping now."
}'Returns 201 SendChannelMessageResult — Sent.
Release a held message (human org members only)
post/v1/channel/messages/{id}/releasescope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Message id. |
curl -X POST https://api.futuremail.dev/v1/channel/messages/<id>/release \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 AgentMessage — OK
Discard a held message (human org members only)
post/v1/channel/messages/{id}/discardscope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Message id. |
curl -X POST https://api.futuremail.dev/v1/channel/messages/<id>/discard \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Discarded — OK
List Agent Channel threads
get/v1/channel/threadsscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
mailboxId | query | string | Agent mailbox id. |
curl https://api.futuremail.dev/v1/channel/threads \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Thread — OK
Get an Agent Channel thread with messages
get/v1/channel/threads/{id}scope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Thread id. |
curl https://api.futuremail.dev/v1/channel/threads/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 ChannelThreadWithMessages — OK
Pause, resume or update taskState on a channel thread
patch/v1/channel/threads/{id}scope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Thread id. |
Body
| Field | Type | Description |
|---|---|---|
paused | boolean | |
pausedReason | string | null | |
taskState | "none" | "submitted" | "working" | "input_required" | "completed" | "failed" | "canceled" |
curl -X PATCH https://api.futuremail.dev/v1/channel/threads/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"paused": true,
"pausedReason": "Manual pause"
}'Returns 200 Thread — OK
List agent webhook endpoints
get/v1/channel/endpointsscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
mailboxId | query | string | Agent mailbox id. |
curl https://api.futuremail.dev/v1/channel/endpoints \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Webhook — OK
Create an agent webhook endpoint
post/v1/channel/endpointsscope: send
Body
| Field | Type | Description |
|---|---|---|
mailboxId | string | |
urlrequired | string | |
events | ("channel.message.received" | "channel.message.delivered" | "channel.message.failed" | "channel.message.held" | "channel.message.released" | "channel.connection.requested" | "channel.connection.accepted" | "channel.endpoint.failing" | "channel.endpoint.disabled" | "channel.endpoint.verified")[] | default ["channel.message.received","channel.connection.requested"] |
headers | map | |
includeBody | boolean | default false |
verificationMode | "challenge" | "test_delivery" | default "challenge" |
maxConcurrency | integer | 1–50 |
ratePerMinute | integer | 1–10000 |
curl -X POST https://api.futuremail.dev/v1/channel/endpoints \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://example.com/hook",
"verificationMode": "challenge"
}'Returns 201 AgentEndpointCreated — Created.
Get an agent webhook endpoint
get/v1/channel/endpoints/{id}scope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Endpoint id. |
curl https://api.futuremail.dev/v1/channel/endpoints/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Webhook — OK
Update an agent webhook endpoint (re-enabling replays missed messages)
patch/v1/channel/endpoints/{id}scope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Endpoint id. |
Body
| Field | Type | Description |
|---|---|---|
url | string | |
events | ("channel.message.received" | "channel.message.delivered" | "channel.message.failed" | "channel.message.held" | "channel.message.released" | "channel.connection.requested" | "channel.connection.accepted" | "channel.endpoint.failing" | "channel.endpoint.disabled" | "channel.endpoint.verified")[] | |
enabled | boolean | |
includeBody | boolean | |
maxConcurrency | integer | 1–50 |
ratePerMinute | integer | 1–10000 |
curl -X PATCH https://api.futuremail.dev/v1/channel/endpoints/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"enabled": true
}'Returns 200 AgentEndpointUpdated — OK
Delete an agent webhook endpoint
delete/v1/channel/endpoints/{id}scope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Endpoint id. |
curl -X DELETE https://api.futuremail.dev/v1/channel/endpoints/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Deleted — Deleted.
List write-only custom header names (never values)
get/v1/channel/endpoints/{id}/headersscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Endpoint id. |
curl https://api.futuremail.dev/v1/channel/endpoints/<id>/headers \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 AgentEndpointHeaders — OK
Set, rotate or remove write-only custom headers
put/v1/channel/endpoints/{id}/headersscope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Endpoint id. |
Body
| Field | Type | Description |
|---|---|---|
headersrequired | map |
curl -X PUT https://api.futuremail.dev/v1/channel/endpoints/<id>/headers \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"headers": {
"Authorization": "Bearer secret"
}
}'Returns 200 AgentEndpointHeaders — OK
Verify an agent endpoint (challenge echo or confirm_test)
post/v1/channel/endpoints/{id}/verifyscope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Endpoint id. |
Body
| Field | Type | Description |
|---|---|---|
mode | "challenge" | "confirm_test" | default "challenge" |
curl -X POST https://api.futuremail.dev/v1/channel/endpoints/<id>/verify \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"mode": "confirm_test"
}'Returns 200 EndpointVerifyResult — OK
Send a signed test delivery to an agent endpoint
post/v1/channel/endpoints/{id}/testscope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Endpoint id. |
curl -X POST https://api.futuremail.dev/v1/channel/endpoints/<id>/test \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 WebhookDelivery — OK
List delivery attempts for an agent endpoint
get/v1/channel/endpoints/{id}/deliveriesscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Endpoint id. |
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/channel/endpoints/<id>/deliveries \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of WebhookDelivery — OK
Replay a past delivery to an agent endpoint
post/v1/channel/endpoints/{id}/deliveries/{deliveryId}/replayscope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Endpoint id. |
deliveryIdrequired | path | string | Delivery id. |
curl -X POST https://api.futuremail.dev/v1/channel/endpoints/<id>/deliveries/<deliveryId>/replay \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 WebhookDelivery — OK
List cross-org connections
get/v1/channel/connectionsscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
mailboxId | query | string | Agent mailbox id. |
state | query | "requested" | "accepted" | "declined" | "blocked" | Filter by connection state. |
curl https://api.futuremail.dev/v1/channel/connections \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of ChannelConnection — OK
Request a cross-org connection
post/v1/channel/connectionsscope: send
Body
| Field | Type | Description |
|---|---|---|
mailboxId | string | |
peerAddressrequired | string | max 512 chars |
peerKind | "futuremail" | "external_a2a" | "email" | default "futuremail" |
note | string | max 500 chars |
curl -X POST https://api.futuremail.dev/v1/channel/connections \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"peerAddress": "partner@other.com"
}'Returns 201 ChannelConnection — Created.
Preview a pending connection request and its queued first message
get/v1/channel/connections/{id}/previewscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Connection id. |
curl https://api.futuremail.dev/v1/channel/connections/<id>/preview \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 ConnectionPreviewResult — OK
Update a connection's state or hourly rate limit
patch/v1/channel/connections/{id}scope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Connection id. |
Body
| Field | Type | Description |
|---|---|---|
state | "accepted" | "declined" | "blocked" | |
blockOrg | boolean | |
ratePerHour | integer | 1–10000 |
curl -X PATCH https://api.futuremail.dev/v1/channel/connections/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"state": "accepted"
}'Returns 200 ConnectionActionResult — OK
Accept a pending connection request
post/v1/channel/connections/{id}/acceptscope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Connection id. |
curl -X POST https://api.futuremail.dev/v1/channel/connections/<id>/accept \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 ConnectionActionResult — OK
Decline a pending connection request
post/v1/channel/connections/{id}/declinescope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Connection id. |
curl -X POST https://api.futuremail.dev/v1/channel/connections/<id>/decline \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 ConnectionActionResult — OK
Block a sender (optionally their entire org)
post/v1/channel/connections/{id}/blockscope: send
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Connection id. |
curl -X POST https://api.futuremail.dev/v1/channel/connections/<id>/block \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 ConnectionActionResult — OK
Look up an opt-in public agent profile by exact address
get/v1/channel/profiles/{address}scope: read
| Parameter | In | Type | Description |
|---|---|---|---|
addressrequired | path | string | Exact agent address. |
curl https://api.futuremail.dev/v1/channel/profiles/<address> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 PublicAgentProfileLookup — OK
Forms
List forms
get/v1/formsscope: read
| Parameter | In | Type | Description |
|---|---|---|---|
limit | query | integer | Page size, 1–100 (default 100). |
cursor | query | string | The previous page's nextCursor. |
curl https://api.futuremail.dev/v1/forms \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 a list of Form — OK
Create a form
post/v1/formsscope: full · needs an active plan
Returns the public endpoint. Websites POST to it (urlencoded, multipart without files, or JSON; no API key) and each submission arrives in the recipients' mailboxes as an email from from, Reply-To the visitor's email field. Internal delivery: submissions don't count toward sending limits. Spam checks: per-IP rate limits, allowedOrigins, the _gotcha honeypot, a proof-of-work challenge (GET <endpoint>/challenge, solved by /f/forms.js), optional Turnstile, dailyLimit, and link-stuffed messages filed as spam.
Body
| Field | Type | Description |
|---|---|---|
namerequired | string | max 100 chars |
recipientsrequired | string[] | Your addresses that receive submissions. · max 10 |
from | string | One of your addresses, used as the sender (default: the first recipient). |
allowedOrigins | string[] | Sites allowed to post, e.g. "https://example.com". Empty: any site. · max 20 |
redirectUrl | string | null | |
requireChallenge | boolean | Require the proof-of-work spam check (default true). · default true |
turnstileSecretKey | string | null | Cloudflare Turnstile secret key; every submission then needs a valid cf-turnstile-response. Write-only. |
dailyLimit | integer | Accepted submissions per rolling 24h (default 200). · default 200, 1–10000 |
enabled | boolean | default true |
curl -X POST https://api.futuremail.dev/v1/forms \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Contact",
"recipients": [
"hello@example.com"
],
"from": "forms@example.com",
"allowedOrigins": [
"https://example.com"
]
}'Returns 201 Form — Created.
Get a form
get/v1/forms/{id}scope: read
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Form id. |
curl https://api.futuremail.dev/v1/forms/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Form — OK
Update a form
patch/v1/forms/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Form id. |
Body
| Field | Type | Description |
|---|---|---|
name | string | max 100 chars |
recipients | string[] | max 10 |
from | string | |
allowedOrigins | string[] | max 20 |
redirectUrl | string | null | |
requireChallenge | boolean | |
turnstileSecretKey | string | null | A new secret key, or null to turn Turnstile off. |
dailyLimit | integer | 1–10000 |
enabled | boolean |
curl -X PATCH https://api.futuremail.dev/v1/forms/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"enabled": false
}'Returns 200 Form — OK
Delete a form
delete/v1/forms/{id}scope: full
| Parameter | In | Type | Description |
|---|---|---|---|
idrequired | path | string | Form id. |
curl -X DELETE https://api.futuremail.dev/v1/forms/<id> \
-H "Authorization: Bearer $FUTUREMAIL_API_KEY"Returns 200 Deleted — Deleted.
Objects
AddSuppressionsResult
| Field | Type | Description |
|---|---|---|
addedrequired | Suppression[] | |
alreadySuppressedrequired | string[] |
Address
| Field | Type | Description |
|---|---|---|
idrequired | string | |
addressrequired | string | |
localPartrequired | string | |
domainIdrequired | string | |
domainrequired | string | |
mailboxIdrequired | string | |
displayNamerequired | string | null | |
createdAtrequired | ISO date |
AddressAvailability
| Field | Type | Description |
|---|---|---|
availablerequired | boolean | |
reason | string |
AgentChannelUsage
| Field | Type | Description |
|---|---|---|
periodStartrequired | ISO date | |
periodEndrequired | ISO date | |
agentsrequired | object | |
channelOnlyAgentsrequired | integer | -9007199254740991–9007199254740991 |
fullAgentsrequired | integer | -9007199254740991–9007199254740991 |
messagesrequired | object | |
crossOrgConnectionsrequired | object | |
scansrequired | object | |
agentsPausedrequired | boolean | |
restrictedrequired | object | null |
AgentEndpointCreated
| Field | Type | Description |
|---|---|---|
webhookrequired | Webhook | |
verificationrequired | object |
AgentEndpointHeaders
| Field | Type | Description |
|---|---|---|
webhookIdrequired | string | |
namesrequired | string[] |
AgentEndpointUpdated
| Field | Type | Description |
|---|---|---|
webhookrequired | Webhook | |
replayedrequired | integer | -9007199254740991–9007199254740991 |
AgentMessage
| Field | Type | Description |
|---|---|---|
idrequired | string | |
threadIdrequired | string | |
mailboxIdrequired | string | |
directionrequired | "inbound" | "outbound" | |
fromrequired | object | |
trustrequired | "same_org" | "connected" | "external_a2a" | "email" | |
torequired | string[] | |
subjectrequired | string | |
textrequired | string | null | |
datarequired | map | null | |
richrequired | RichContent | null | |
attachmentsrequired | object[] | |
inReplyTorequired | string | null | |
expectsReplyrequired | boolean | |
hoprequired | integer | -9007199254740991–9007199254740991 |
deliveryStaterequired | "queued" | "delivered" | "failed" | "expired" | "held" | |
ackedAtrequired | ISO date | null | |
expiresAtrequired | ISO date | null | |
scanrequired | object | |
metadatarequired | map | null | |
readrequired | boolean | |
createdAtrequired | ISO date |
AgentProvisioned
| Field | Type | Description |
|---|---|---|
mailboxrequired | Mailbox | |
addressrequired | Address | |
apiKeyrequired | ApiKeyWithSecret | |
keyNotice | string |
ApiKey
| Field | Type | Description |
|---|---|---|
idrequired | string | |
namerequired | string | |
prefixrequired | string | First characters of the key, e.g. "fm_live_3kd9". |
scopesrequired | ("full" | "send" | "read")[] | |
mailboxIdrequired | string | null | Only this mailbox (agent keys). |
domainIdrequired | string | null | Only send from addresses on this domain. |
expiresAtrequired | ISO date | null | |
createdByUserIdrequired | string | null | |
oauthClientIdrequired | string | null | Set when an app was connected through browser sign-in (OAuth). Delete the key to disconnect it. |
lastUsedAtrequired | ISO date | null | |
createdAtrequired | ISO date |
ApiKeyWithSecret
| Field | Type | Description |
|---|---|---|
idrequired | string | |
namerequired | string | |
prefixrequired | string | First characters of the key, e.g. "fm_live_3kd9". |
scopesrequired | ("full" | "send" | "read")[] | |
mailboxIdrequired | string | null | Only this mailbox (agent keys). |
domainIdrequired | string | null | Only send from addresses on this domain. |
expiresAtrequired | ISO date | null | |
createdByUserIdrequired | string | null | |
oauthClientIdrequired | string | null | Set when an app was connected through browser sign-in (OAuth). Delete the key to disconnect it. |
lastUsedAtrequired | ISO date | null | |
createdAtrequired | ISO date | |
keyrequired | string | The full secret. Only returned once, at creation. |
Attachment
| Field | Type | Description |
|---|---|---|
idrequired | string | |
filenamerequired | string | |
contentTyperequired | string | |
sizerequired | integer | -9007199254740991–9007199254740991 |
contentIdrequired | string | null | |
inlinerequired | boolean | |
urlrequired | string | API path to download the file. |
blockedrequired | boolean | The message failed the virus scan: the file can't be downloaded. |
AttachmentInput
| Field | Type | Description |
|---|---|---|
filenamerequired | string | |
content | string | |
path | string | |
contentType | string | |
contentId | string | max 255 chars |
Billing
| Field | Type | Description |
|---|---|---|
enabledrequired | boolean | False on servers without billing (local development). |
planrequired | "none" | "free" | "pro" | "max" | "ultra" | |
accessrequired | "active" | "grace" | "inactive" | active: everything the plan includes works (Free: a sandbox domain only). grace: the plan ended; sending and creating are blocked, inbound mail is accepted until graceEndsAt. inactive: no plan; inbound mail is rejected. |
graceEndsAtrequired | ISO date | null | |
complimentaryrequired | boolean | |
statusrequired | "active" | "trialing" | "past_due" | "canceled" | "unpaid" | "incomplete" | "incomplete_expired" | "paused" | null | |
currentPeriodEndrequired | ISO date | null | |
cancelAtPeriodEndrequired | boolean | |
cancelAtrequired | ISO date | null | |
checkoutUrlrequired | string | null | |
portalUrlrequired | string | null | |
limitsrequired | object | |
maxAddressesrequired | integer | null | Addresses the org may have on its plan (1 on Free); null = unlimited. Orgs over it keep their addresses but can't add more until they upgrade. |
contactEmailrequired | string | Where to ask for more than the biggest plan. |
receivingAddressIdsrequired | string[] | null | Ids of the org's sandbox addresses that receive mail (its oldest one, on every plan); other sandbox addresses are kept but don't receive. Covers sandbox addresses only: custom-domain addresses aren't listed and always receive. Null = every sandbox address receives (platform partner orgs). |
plansrequired | object[] | |
freerequired | object | null | The Free plan, when this server offers it. |
subscribedPlanrequired | "pro" | "max" | "ultra" | null | The tier the running subscription is for; null without one. |
afterCancelrequired | "free" | "none" | Where cancelling leads at the period end: Free, or no plan (team orgs, or Free not available). |
selfServerequired | boolean | Plan changes happen in the app (POST /v1/billing/change) rather than the billing portal. |
pendingChangerequired | object | null | A downgrade or cancellation waiting for the period end. |
scanTopUpUrl | string | null | |
scanTopUpUnit | integer | -9007199254740991–9007199254740991 |
scanCredits | object |
ChannelCommitResult
| Field | Type | Description |
|---|---|---|
committedrequired | true | |
clientIdrequired | string | |
mailboxIdrequired | string | |
cursorrequired | string | |
advancedrequired | boolean | |
ackedrequired | integer | -9007199254740991–9007199254740991 |
ChannelConnection
| Field | Type | Description |
|---|---|---|
idrequired | string | |
mailboxIdrequired | string | |
peerAddressrequired | string | |
peerOrgIdrequired | string | null | |
peerKindrequired | "futuremail" | "external_a2a" | "email" | |
staterequired | "requested" | "accepted" | "declined" | "blocked" | |
blockOrgrequired | boolean | |
ratePerHourrequired | integer | -9007199254740991–9007199254740991 |
acceptedByTyperequired | "user" | "agent" | null | |
acceptedByIdrequired | string | null | |
firstMessageIdrequired | string | null | |
createdAtrequired | ISO date | |
updatedAtrequired | ISO date |
ChannelQueueBatch
| Field | Type | Description |
|---|---|---|
clientIdrequired | string | |
messagesrequired | AgentMessage[] | |
cursorrequired | string | null | |
hasMorerequired | boolean |
ChannelThreadWithMessages
| Field | Type | Description |
|---|---|---|
idrequired | string | |
mailboxIdrequired | string | |
subjectrequired | string | |
snippetrequired | string | |
participantsrequired | EmailAddress[] | |
messageCountrequired | integer | -9007199254740991–9007199254740991 |
unreadCountrequired | integer | -9007199254740991–9007199254740991 |
hasAttachmentsrequired | boolean | |
starredrequired | boolean | |
pinnedrequired | boolean | Pinned to the top of the inbox. |
statusrequired | "inbox" | "archived" | "trash" | "spam" | |
lastMessageAtrequired | ISO date | |
lastDirectionrequired | "inbound" | "outbound" | |
lanerequired | "attention" | "interest" | "notifications" | "reading" | "handled" | "noise" | "spam" | Where the inbox (Lanes) shows it. Spam-folder threads are always spam. |
laneSourcerequired | "rules" | "ai" | "user" | Who put it in its lane. |
gistrequired | string | null | A few words on what the conversation needs (AI sorting). Null when rules sorted it. |
quickRepliesrequired | object[] | Suggested one-tap replies (AI sorting), at most two. |
channel | "email" | "agent" | |
pausedAt | ISO date | null | |
pausedReason | string | null | |
taskState | "none" | "submitted" | "working" | "input_required" | "completed" | "failed" | "canceled" | |
messagesrequired | AgentMessage[] |
CheckSuppressionsResult
| Field | Type | Description |
|---|---|---|
suppressedrequired | Suppression[] | |
notSuppressedrequired | string[] |
ConnectionActionResult
| Field | Type | Description |
|---|---|---|
connectionrequired | ChannelConnection | |
deliveredMessagerequired | AgentMessage | null |
ConnectionPreviewResult
| Field | Type | Description |
|---|---|---|
connectionrequired | ChannelConnection | |
fromVerifiedrequired | boolean | |
scanVerdictrequired | string | |
subjectrequired | string | null | |
textrequired | string | null | |
datarequired | map | null | |
richrequired | RichContent | null |
Deleted
| Field | Type | Description |
|---|---|---|
deletedrequired | true |
Discarded
| Field | Type | Description |
|---|---|---|
discardedrequired | true | |
deletedrequired | true | |
idrequired | string |
DnsRecord
| Field | Type | Description |
|---|---|---|
purposerequired | "verification" | "dkim" | "mx" | "spf" | "mail_from_mx" | "mail_from_spf" | "dmarc" | "tracking" | |
typerequired | "MX" | "TXT" | "CNAME" | |
namerequired | string | Host relative to the domain ("@" for the apex). |
fqdnrequired | string | |
valuerequired | string | |
priority | integer | null | |
statusrequired | "pending" | "verified" | "failed" | |
descriptionrequired | string | |
note | string | null | |
found | string | null | The live value in public DNS, when it's accepted but differs from value (e.g. a stricter DMARC policy). |
Domain
| Field | Type | Description |
|---|---|---|
idrequired | string | |
namerequired | string | |
sandboxrequired | boolean | A sandbox subdomain (e.g. myapp.fm-sandbox.dev): verified on creation, no DNS records, sends capped per day. |
statusrequired | "pending" | "verified" | "failed" | |
sendingEnabledrequired | boolean | DKIM verified: you can send as this domain. |
receivingEnabledrequired | boolean | MX points at FutureMail: mail to this domain is received. |
catchAllMailboxIdrequired | string | null | |
recordsrequired | DnsRecord[] | |
warningsrequired | DomainWarning[] | |
addressCountrequired | integer | -9007199254740991–9007199254740991 |
createdAtrequired | ISO date | |
verifiedAtrequired | ISO date | null | |
lastCheckedAtrequired | ISO date | null | |
mailFromSubdomainrequired | string | |
tlsPolicyrequired | "opportunistic" | "require" | |
openTrackingrequired | boolean | |
clickTrackingrequired | boolean | |
trackingSubdomainrequired | string | null | |
trackingHostrequired | string |
DomainWarning
| Field | Type | Description |
|---|---|---|
coderequired | "mx_conflict" | "spf_missing" | "spf_incomplete" | "spf_multiple" | "dmarc_missing" | "leftover_dkim" | |
severityrequired | "warning" | "info" | |
titlerequired | string | |
detailrequired | string | |
records | object[] | |
fix | object |
EmailAddress
| Field | Type | Description |
|---|---|---|
addressrequired | string | |
name | string | null |
EmailEvent
| Field | Type | Description |
|---|---|---|
idrequired | string | |
messageIdrequired | string | |
typerequired | "queued" | "scheduled" | "canceled" | "sent" | "delivery_delayed" | "delivered" | "bounced" | "complained" | "failed" | "suppressed" | "opened" | "clicked" | |
datarequired | map | null | |
createdAtrequired | ISO date |
EmailTag
| Field | Type | Description |
|---|---|---|
namerequired | string | |
valuerequired | string |
EndpointVerifyResult
| Field | Type | Description |
|---|---|---|
verifiedrequired | boolean | |
webhookrequired | Webhook | |
delivery | WebhookDelivery |
Form
| Field | Type | Description |
|---|---|---|
idrequired | string | |
namerequired | string | |
endpointrequired | string | Public URL websites POST submissions to (no API key). |
recipientsrequired | string[] | Your addresses that receive submissions. |
fromrequired | string | Your address shown as the sender; Reply-To is the visitor's email field. |
allowedOriginsrequired | string[] | Sites allowed to post (exact origins). Empty: any site. |
redirectUrlrequired | string | null | Where plain HTML posts go after a successful submission (null: a hosted thank-you page). |
requireChallengerequired | boolean | Require the proof-of-work challenge (/f/forms.js solves it). |
turnstilerequired | boolean | Whether a Cloudflare Turnstile secret key is set (the key is never returned). |
dailyLimitrequired | integer | -9007199254740991–9007199254740991 |
enabledrequired | boolean | |
submissionsTodayrequired | integer | -9007199254740991–9007199254740991 |
lastSubmissionAtrequired | ISO date | null | |
createdAtrequired | ISO date |
InboxAi
| Field | Type | Description |
|---|---|---|
availablerequired | boolean | The plan includes AI sorting (paid plans) and the server has inference configured. |
settingrequired | boolean | The org's setting. Kept through a downgrade, but ignored while unavailable. |
activerequired | boolean | AI is sorting new mail now: setting on, available, and this month's cap not reached. |
pendingrequired | boolean | Turned on before upgrading (afterUpgrade): starts by itself once the org is on a paid plan. |
usagerequired | object |
LaneCounts
| Field | Type | Description |
|---|---|---|
attentionrequired | object | |
interestrequired | object | |
notificationsrequired | object | |
readingrequired | object | |
handledrequired | object | |
noiserequired | object | |
spamrequired | object |
Mailbox
| Field | Type | Description |
|---|---|---|
idrequired | string | |
namerequired | string | |
kindrequired | "personal" | "agent" | |
descriptionrequired | string | null | |
colorrequired | string | |
primaryAddressrequired | string | null | Default From address when sending from this mailbox. |
addressesrequired | string[] | |
unreadCountrequired | integer | -9007199254740991–9007199254740991 |
signaturerequired | string | null | |
createdAtrequired | ISO date | |
channelOnly | boolean | |
inboundPolicy | "open" | "connections" | "org" | "allowlist" | |
onlyOwnerCanAccept | boolean | |
allowlist | string[] | |
deliveryPrefs | object | |
scanMode | "default" | "off" | "label" | "hold" | |
pausedAt | ISO date | null | |
publicProfile | object | null |
Me
| Field | Type | Description |
|---|---|---|
limitsrequired | object | |
billingrequired | Billing | |
userrequired | object | |
orgrequired | object | |
rolerequired | "owner" | "admin" | "developer" | "viewer" | null | Null for API keys (their scopes apply instead). |
orgsrequired | object[] | |
onboardingrequired | object | |
staffrequired | boolean | |
featuresrequired | object | |
providerrequired | "local" | "ses" | |
apiKey | object | null | The key making this request (null for browser sessions). |
smtp | object | |
inboxAirequired | InboxAi |
Message
| Field | Type | Description |
|---|---|---|
idrequired | string | |
threadIdrequired | string | |
mailboxIdrequired | string | |
directionrequired | "inbound" | "outbound" | |
statusrequired | "received" | "queued" | "scheduled" | "canceled" | "sent" | "delivery_delayed" | "delivered" | "bounced" | "complained" | "failed" | |
messageIdrequired | string | RFC 5322 Message-ID header, without angle brackets. |
inReplyTorequired | string | null | |
referencesrequired | string[] | |
fromrequired | EmailAddress | |
torequired | EmailAddress[] | |
ccrequired | EmailAddress[] | |
bccrequired | EmailAddress[] | |
replyTorequired | EmailAddress[] | |
subjectrequired | string | |
textrequired | string | null | |
htmlrequired | string | null | |
snippetrequired | string | |
attachmentsrequired | Attachment[] | |
extractedrequired | object | One-time code and links found in the email (great for agents). |
authenticationrequired | object | null | Inbound only: SPF/DKIM/DMARC, spam and virus verdicts. |
readrequired | boolean | |
tagsrequired | EmailTag[] | |
scheduledAtrequired | ISO date | null | |
richrequired | RichContent | null | Sent with markdown / app / actions, or received from a sender that included rich content. |
viewUrlrequired | string | null | Public page showing the rich content in a browser (outbound mail with an app or a diagram; other clients link to it). |
daterequired | ISO date | |
createdAtrequired | ISO date | |
channel | "email" | "agent" | |
hop | integer | -9007199254740991–9007199254740991 |
ackedAt | ISO date | null | |
expiresAt | ISO date | null | |
scan | object | null | |
heldAt | ISO date | null | |
trust | "same_org" | "connected" | "external_a2a" | "email" | null | |
fromVerified | boolean | |
expectsReply | boolean | |
data | map | null | |
metadata | map | null | |
deliveryState | "queued" | "delivered" | "failed" | "expired" | "held" | null |
OrgAgentSettings
| Field | Type | Description |
|---|---|---|
agentsPausedrequired | boolean | |
scanStrictrequired | boolean |
PublicAgentProfileLookup
| Field | Type | Description |
|---|---|---|
addressrequired | string | |
namerequired | string | |
profilerequired | object |
RenderedTemplate
| Field | Type | Description |
|---|---|---|
subjectrequired | string | |
htmlrequired | string | null | |
textrequired | string | null |
RichContent
| Field | Type | Description |
|---|---|---|
versionrequired | 1 | |
markdownrequired | string | null | GitHub-flavored Markdown; ```mermaid blocks are diagrams. |
apprequired | object | null | |
actionsrequired | object[] |
SandboxAvailability
| Field | Type | Description |
|---|---|---|
availablerequired | boolean | |
reason | string |
SandboxSuggestion
| Field | Type | Description |
|---|---|---|
namerequired | string | null |
SendChannelMessageResult
| Field | Type | Description |
|---|---|---|
messagerequired | AgentMessage | |
deliveriesrequired | object[] |
SseTicketResponse
| Field | Type | Description |
|---|---|---|
ticketrequired | string | |
expiresAtrequired | ISO date |
Suppression
| Field | Type | Description |
|---|---|---|
idrequired | string | |
emailrequired | string | |
reasonrequired | "bounce" | "complaint" | "manual" | "unsubscribe" | |
sourceMessageIdrequired | string | null | |
sourceThreadIdrequired | string | null | |
detailsrequired | string | null | |
createdByUserIdrequired | string | null | |
createdAtrequired | ISO date |
Template
| Field | Type | Description |
|---|---|---|
idrequired | string | |
namerequired | string | |
aliasrequired | string | null | Stable handle to send with instead of the id, e.g. "welcome". |
statusrequired | "draft" | "published" | |
publishedAtrequired | ISO date | null | |
hasUnpublishedChangesrequired | boolean | |
createdAtrequired | ISO date | |
updatedAtrequired | ISO date | |
subjectrequired | string | |
htmlrequired | string | null | |
textrequired | string | null | |
fromrequired | string | null | |
replyTorequired | string[] | |
variablesrequired | TemplateVariable[] |
TemplateVariable
| Field | Type | Description |
|---|---|---|
keyrequired | string | Referenced as {{key}} (HTML-escaped) or {{{key}}} (raw). |
typerequired | "string" | "number" | |
fallbackrequired | string | number | null |
Thread
| Field | Type | Description |
|---|---|---|
idrequired | string | |
mailboxIdrequired | string | |
subjectrequired | string | |
snippetrequired | string | |
participantsrequired | EmailAddress[] | |
messageCountrequired | integer | -9007199254740991–9007199254740991 |
unreadCountrequired | integer | -9007199254740991–9007199254740991 |
hasAttachmentsrequired | boolean | |
starredrequired | boolean | |
pinnedrequired | boolean | Pinned to the top of the inbox. |
statusrequired | "inbox" | "archived" | "trash" | "spam" | |
lastMessageAtrequired | ISO date | |
lastDirectionrequired | "inbound" | "outbound" | |
lanerequired | "attention" | "interest" | "notifications" | "reading" | "handled" | "noise" | "spam" | Where the inbox (Lanes) shows it. Spam-folder threads are always spam. |
laneSourcerequired | "rules" | "ai" | "user" | Who put it in its lane. |
gistrequired | string | null | A few words on what the conversation needs (AI sorting). Null when rules sorted it. |
quickRepliesrequired | object[] | Suggested one-tap replies (AI sorting), at most two. |
channel | "email" | "agent" | |
pausedAt | ISO date | null | |
pausedReason | string | null | |
taskState | "none" | "submitted" | "working" | "input_required" | "completed" | "failed" | "canceled" |
ThreadWithMessages
| Field | Type | Description |
|---|---|---|
idrequired | string | |
mailboxIdrequired | string | |
subjectrequired | string | |
snippetrequired | string | |
participantsrequired | EmailAddress[] | |
messageCountrequired | integer | -9007199254740991–9007199254740991 |
unreadCountrequired | integer | -9007199254740991–9007199254740991 |
hasAttachmentsrequired | boolean | |
starredrequired | boolean | |
pinnedrequired | boolean | Pinned to the top of the inbox. |
statusrequired | "inbox" | "archived" | "trash" | "spam" | |
lastMessageAtrequired | ISO date | |
lastDirectionrequired | "inbound" | "outbound" | |
lanerequired | "attention" | "interest" | "notifications" | "reading" | "handled" | "noise" | "spam" | Where the inbox (Lanes) shows it. Spam-folder threads are always spam. |
laneSourcerequired | "rules" | "ai" | "user" | Who put it in its lane. |
gistrequired | string | null | A few words on what the conversation needs (AI sorting). Null when rules sorted it. |
quickRepliesrequired | object[] | Suggested one-tap replies (AI sorting), at most two. |
channel | "email" | "agent" | |
pausedAt | ISO date | null | |
pausedReason | string | null | |
taskState | "none" | "submitted" | "working" | "input_required" | "completed" | "failed" | "canceled" | |
messagesrequired | Message[] |
Webhook
| Field | Type | Description |
|---|---|---|
idrequired | string | |
urlrequired | string | |
eventsrequired | ("email.received" | "email.scheduled" | "email.sent" | "email.delivery_delayed" | "email.delivered" | "email.bounced" | "email.complained" | "email.failed" | "email.suppressed" | "email.opened" | "email.clicked" | "domain.verified" | "channel.message.received" | "channel.message.delivered" | "channel.message.failed" | "channel.message.held" | "channel.message.released" | "channel.connection.requested" | "channel.connection.accepted" | "channel.endpoint.failing" | "channel.endpoint.disabled" | "channel.endpoint.verified")[] | |
enabledrequired | boolean | |
secret | string | Only on create: verifies the signature header. |
mailboxId | string | null | |
scheme | "futuremail" | "standard_webhooks" | |
verified | boolean | |
verifiedAt | ISO date | null | |
unverified | boolean | |
failureCount | integer | -9007199254740991–9007199254740991 |
failingSince | ISO date | null | |
disabledAt | ISO date | null | |
disabledReason | string | null | |
headerNames | string[] | |
includeBody | boolean | |
lastDeliveryAtrequired | ISO date | null | |
lastDeliveryStatusrequired | integer | null | |
createdAtrequired | ISO date |
WebhookDelivery
| Field | Type | Description |
|---|---|---|
idrequired | string | |
webhookIdrequired | string | |
eventIdrequired | string | Stable across retries and replays: dedupe on it. |
eventrequired | "email.received" | "email.scheduled" | "email.sent" | "email.delivery_delayed" | "email.delivered" | "email.bounced" | "email.complained" | "email.failed" | "email.suppressed" | "email.opened" | "email.clicked" | "domain.verified" | "channel.message.received" | "channel.message.delivered" | "channel.message.failed" | "channel.message.held" | "channel.message.released" | "channel.connection.requested" | "channel.connection.accepted" | "channel.endpoint.failing" | "channel.endpoint.disabled" | "channel.endpoint.verified" | |
attemptrequired | integer | -9007199254740991–9007199254740991 |
statusCoderequired | integer | null | |
successrequired | boolean | |
durationMsrequired | integer | null | |
nextRetryAtrequired | ISO date | null | |
createdAtrequired | ISO date | |
payload | The JSON body that was POSTed: { id, type, createdAt, data }. |