Skip to content

Order domains and mailboxes with code

Search for domains, buy them with mailboxes, read the SMTP and IMAP logins and listen for signed webhooks. Plain JSON over HTTPS.

Quickstart

From a search to a mailbox login

Each step is a curl command you can paste into a terminal.

1. Create a key and add a card

In the dashboard, open Settings, then API keys, and create a key with Full access. Add a card under Settings, then Billing: buying needs one, and the API cannot add it. Export the key.

export YESBOXES_KEY=yb_live_...
curl https://yesboxes.io/api/v1/workspace -H "Authorization: Bearer $YESBOXES_KEY"
# {"id":"...","name":"Acme","paymentMethodOnFile":true}

2. Search for a domain

Results show whether each name is free and its yearly price in cents.

curl "https://yesboxes.io/api/v1/domains/search?q=acme-outreach" -H "Authorization: Bearer $YESBOXES_KEY"
# {"results":[{"domain":"acme-outreach.com","tld":"com","available":true,"recommended":true,"priceCents":1899}, ...]}

3. Get a quote

Add dryRun to the order. Nothing is charged and no Idempotency-Key is needed.

curl -X POST https://yesboxes.io/api/v1/orders -H "Authorization: Bearer $YESBOXES_KEY" \
  -H "Content-Type: application/json" \
  -d '{"dryRun":true,"domains":[{"name":"acme-outreach.com"}],"mailboxesPerDomain":2,"namingPattern":{"names":[{"firstName":"Ada","lastName":"Lovelace"},{"firstName":"Alan","lastName":"Turing"}]}}'
# {"quote":{"domains":[{"domain":"acme-outreach.com","priceCents":1899}],"totalCents":1899,"paymentMethodOnFile":true,
#   "mailboxes":{"count":2,"currentQuantity":0,"newQuantity":2,"unitPriceCents":250,"monthlyTotalCents":500,"monthlyDeltaCents":500}}}

4. Place the order

Send the same body without dryRun and with an Idempotency-Key. If the connection drops, repeat the call with the same key: you get the same order, never a second one. Add maxTotalCents to refuse a price above your limit.

curl -X POST https://yesboxes.io/api/v1/orders -H "Authorization: Bearer $YESBOXES_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: acme-outreach-1" \
  -d '{"domains":[{"name":"acme-outreach.com"}],"mailboxesPerDomain":2,"namingPattern":{"names":[{"firstName":"Ada","lastName":"Lovelace"},{"firstName":"Alan","lastName":"Turing"}]}}'
# 201 {"id":"6650...","status":"processing","totalCents":1899,
#   "domains":[{"domain":"acme-outreach.com","domainId":"6650...","state":"registering","reason":null,
#     "mailboxes":["ada.lovelace@acme-outreach.com","alan.turing@acme-outreach.com"]}],"createdAt":"..."}
# With no card on file, the same call returns:
# 402 {"error":{"code":"payment_required","message":"Add a payment method before buying.",
#   "details":{"reason":"no_payment_method","billingUrl":"https://yesboxes.io/settings/billing"}}}
# Add the card in the dashboard, then repeat the call with the same Idempotency-Key.

5. Wait for the order, then read the logins

Poll the order until status is completed and every domain state is ready, or listen for order.completed. Then ask for the logins of the domain's mailboxes. Passwords come back only from this call, are never stored for replay and are logged against your key.

curl https://yesboxes.io/api/v1/orders/6650... -H "Authorization: Bearer $YESBOXES_KEY"
# {"id":"6650...","status":"completed", ...}
curl -X POST https://yesboxes.io/api/v1/mailboxes/credentials -H "Authorization: Bearer $YESBOXES_KEY" \
  -H "Content-Type: application/json" \
  -d '{"domainId":"6650..."}'
# {"credentials":[{"mailboxId":"...","email":"ada.lovelace@acme-outreach.com","username":"ada.lovelace@acme-outreach.com","password":"...",
#   "smtp":{"host":"...","sslPort":465,"starttlsPort":587},"imap":{"host":"...","port":993},"paused":false}, ...],"notReady":[]}

6. Or connect a domain you own

Preview shows what yesboxes would change in your DNS. Connect creates the domain; a few seconds later GET /domains/{id} shows the nameservers to set at your registrar in ns.expected. Then check them, and read ns.status.

curl -X POST https://yesboxes.io/api/v1/domains/connect/preview -H "Authorization: Bearer $YESBOXES_KEY" -H "Content-Type: application/json" \
  -d '{"names":["example-sales.com"]}'

curl -X POST https://yesboxes.io/api/v1/domains/connect -H "Authorization: Bearer $YESBOXES_KEY" -H "Content-Type: application/json" \
  -H "Idempotency-Key: connect-example-sales-1" \
  -d '{"names":["example-sales.com"]}'
# 201 {"domains":[{"id":"6651...","status":"awaiting_nameservers", ...}]}

curl https://yesboxes.io/api/v1/domains/6651... -H "Authorization: Bearer $YESBOXES_KEY"
# {"id":"6651...","ns":{"expected":["ada.ns.cloudflare.com","bob.ns.cloudflare.com"],"status":"pending", ...}, ...}

curl -X POST https://yesboxes.io/api/v1/domains/6651.../check-nameservers -H "Authorization: Bearer $YESBOXES_KEY"
# {"id":"6651...","ns":{"status":"matched", ...}, ...}

Basics

How the API behaves

Base URL and keys

Every path in this reference sits under https://yesboxes.io/api/v1. Send the key as Authorization: Bearer yb_live_…. Create keys in the dashboard under Settings, then API keys. Money is whole cents in USD, times are ISO 8601 and field names are camelCase.

Scopes

A key is either Read only (domains:read and mailboxes:read) or Full access, or you pick scopes yourself. A call without the scope it needs returns 403 insufficient_scope and lists the missing scopes in details.required. Each operation below names its scopes.

domains:read
List and read domains, DNS records, orders and Cloudflare connections.
domains:write
Buy and connect domains, edit DNS, rotate and disconnect.
mailboxes:read
List and read mailboxes and their insights.
mailboxes:write
Create, change and cancel mailboxes.
credentials:read
Read mailbox passwords, reset them and export them.
billing:charge
Place calls that charge the card: orders, domain purchases and new mailboxes.
webhooks
Manage webhook endpoints and deliveries.
sequencers
Manage sequencer connections and exports.

Paying

Calls that spend money need a card on file. Add it in the dashboard under Settings, then Billing: the API cannot add one. Without a card, or while a payment has failed, those calls return 402 payment_required with details.reason and a details.billingUrl. Reads, updates, deletes and dry runs work without a card. Domains are charged in the request. Mailboxes are charged by the month, prorated on your next invoice. A daily cap applies to new domain spend and to new mailboxes per workspace; going over returns 429 limit_exceeded.

Idempotency

Send an Idempotency-Key (up to 255 characters) on POST and DELETE calls. The same key with the same request returns the stored response for 24 hours, with Idempotent-Replayed: true. A different body with the same key returns 422. Only 2xx responses are stored, so you can fix a 402 or a 429 and retry with the same key. The key is required on POST /orders, POST /domains, POST /domains/{id}/mailboxes and DELETE /domains/{id}, except on a dry run. On orders and domain purchases the key stays bound to the purchase after the 24 hours, so a retry cannot buy twice. Responses that carry a password are never stored for replay.

Dry runs and price limits

Add "dryRun": true to POST /orders, POST /domains or POST /domains/{id}/mailboxes to get a quote and charge nothing. Add maxTotalCents to an order or a purchase to refuse a total above your limit with 409 price_exceeded.

Lists

List calls take limit (1 to 200, default 50) and cursor, and return { <plural>: [...], nextCursor }. nextCursor is null on the last page.

Errors

Every error has the same shape: { "error": { "code", "message", "details"? } }. Switch on code, not on the message.

400
invalid_request, idempotency_key_required
401
unauthorized
402
payment_required, payment_failed
403
forbidden, insufficient_scope
404
not_found
409
unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded, already_created
422
idempotency_key_reuse
424
credential_invalid
429
rate_limited, limit_exceeded
500, 501
internal_error, not_available

busy means another request holds a lock: retry after a second. credential_invalid means the Cloudflare connection stopped working and needs a new token in the dashboard.

Rate limits

Limits count per workspace, not per key, so extra keys do not raise them. Responses carry X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset. Over the limit you get 429 rate_limited with Retry-After in seconds.

std: 600 per minute
Everything not listed below.
heavy: 30 per minute
Purchases, domain connects and quotes: they call the registrar, Cloudflare or DNS.
search: 60 per minute
Domain search.
secret: 60 per minute
Endpoints that return mailbox passwords, and sequencer exports.

Connecting domains is limited to 20 names per hour, previews to 30 per 10 minutes and a nameserver check to one per minute per domain. The dashboard shares these three limits.

Mailbox logins

A mailbox has no password until provisioning finishes. Create it, wait for mailbox.active (or poll until status is active), then call a credentials endpoint. Four endpoints return passwords: the single and bulk credentials calls, the CSV export and the password reset. They need credentials:read, send Cache-Control: no-store and write an audit entry with the key and the IP address.

Connecting a domain you own

POST /domains/connect returns the domain as awaiting_nameservers. A few seconds later GET /domains/{id} shows the nameservers to set at your registrar in ns.expected, and the domain.connecting webhook carries them too. Call POST /domains/{id}/check-nameservers and read ns.status: matched moves the domain on, mismatch and review need a look. With mode: "cloudflare" yesboxes writes the records into your own Cloudflare zones instead, using a connection from POST /cloudflare-credentials. In the preview, canChallenge tells you an ownership challenge is available in the dashboard.

Webhooks

Signed events, verified by you

Add an endpoint with POST /webhooks. Its signing secret is returned once.

Each delivery is a POST with the body { id, type, createdAt, data }. data holds { orderId, domains, totalCents?, reason? } for orders, { domainId, domain, reason?, expiresAt? } for domains and { mailboxId, email, domainId, reason? } for mailboxes. Any 2xx counts as delivered. A failed delivery is tried up to 8 times over about a day. You can replay one with POST /webhook-deliveries/{id}/replay. Events never carry passwords.

Headers: X-Event, X-Event-Id, X-Timestamp (Unix seconds) and X-Signature. The signature is v1= plus the hex HMAC-SHA256 of <X-Timestamp>.<raw body> with your secret. Verify against the raw body, before parsing it, and reject timestamps more than five minutes old. During a secret rotation the header can hold several comma-separated v1= values: accept any match.

import { createHmac, timingSafeEqual } from "node:crypto";

// rawBody: the request body as a string, before JSON.parse.
export function verify(secret, headers, rawBody) {
  const ts = headers["x-timestamp"];
  if (!/^\d{1,12}$/.test(ts) || Math.abs(Date.now() / 1000 - Number(ts)) > 300) return false;
  const want = Buffer.from("v1=" + createHmac("sha256", secret).update(`${ts}.${rawBody}`).digest("hex"));
  return String(headers["x-signature"]).split(",").some((part) => {
    const got = Buffer.from(part.trim());
    return got.length === want.length && timingSafeEqual(got, want);
  });
}

To test your code, this secret, timestamp and body must give this signature.

secret     whsec_test_secret
timestamp  1764028800
body       {"id":"evt_1","type":"order.paid","createdAt":"2026-11-25T00:00:00.000Z","data":{"orderId":"o1"}}
signature  v1=69420af08adcf100777e14b6f886e62695e48a515fa7968572f1624a943577c9

Event types

Order
order.created, order.paid, order.payment_failed, order.completed, order.partially_failed, order.failed
Bought domain
domain.registering, domain.active, domain.failed, domain.refunded, domain.renewed, domain.expired
Connected domain
domain.connecting, domain.nameservers_matched, domain.active, domain.removed
Domain changes
domain.rotated, domain.moved
Mailbox
mailbox.provisioning, mailbox.active, mailbox.failed, mailbox.updated, mailbox.address_changed, mailbox.password_reset, mailbox.forwarding_changed, mailbox.removal_scheduled, mailbox.cancelled, mailbox.paused, mailbox.resumed
Health
health.domain_blocklisted, health.domain_dns_drift, health.mailbox_bounce_rate_high, health.domain_bounce_rate, health.cloudflare_credential_invalid, health.recovered
Billing
billing.payment_failed, billing.payment_recovered

Reference

Every endpoint

52 operations. The same content is in the OpenAPI file, with the scopes of each in x-required-scopes.

Workspace

The workspace behind the key, and its alerts.

get/workspace

Get the workspace

Scopes:none· 600 requests per minute

Responses

  • 200The workspace.Workspace
  • 401unauthorized: the key is missing, revoked or expired.
  • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
  • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
get/alerts

List alerts

Health alerts for the workspace.

Scopes:none· 600 requests per minute

Parameters

  • statusquery: open | resolved | all

Responses

  • 200Alerts.{ alerts }
  • 400invalid_request or idempotency_key_required.
  • 401unauthorized: the key is missing, revoked or expired.
  • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
  • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).

Domains

Buy domains or connect ones you own.

get/domains/search

Search for available domains

Searches the registrar, so it has its own rate class.

Scopes:domains:read· 60 requests per minute

Parameters

  • qquery: stringrequired

    A name or a name with a TLD.

Responses

  • 200Results with yearly prices.{ results }
  • 400invalid_request or idempotency_key_required.
  • 401unauthorized: the key is missing, revoked or expired.
  • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
  • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
get/domains

List domains

Scopes:domains:read· 600 requests per minute

Parameters

  • limitquery: integer

    Page size, 1 to 200. Default 50.

  • cursorquery: string

    Opaque cursor from nextCursor. A bad cursor gives 400.

  • statusquery: pending_payment | registering | awaiting_nameservers | configuring_dns | active | failed | expired | removed
  • sourcequery: purchased | connected
  • namequery: string

    Substring of the domain name.

Responses

  • 200A page of domains.{ domains, nextCursor }
  • 400invalid_request or idempotency_key_required.
  • 401unauthorized: the key is missing, revoked or expired.
  • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
  • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
post/domains

Buy domains

Registers the domains and charges the first year to the card on file. Needs a card on file (Settings, Billing in the dashboard); without one the call returns 402. A dry run needs no card. Pass maxTotalCents to refuse a price above your limit. A daily spend cap applies to API purchases.

Scopes:domains:writebilling:charge· 30 requests per minute

Parameters

  • Idempotency-Keyheader: string

    Required unless the body has dryRun: true. Up to 255 characters. A retry with the same key and body replays the stored response for 24 hours; a different body gives 422.

Request body

  • domains{ name, redirectUrl }[]required

    1 to 50 domains.

  • maxTotalCentsinteger
  • dryRunboolean

Responses

  • 200Dry run: the quote. Nothing is charged.{ quote }
  • 201Purchase recorded. Poll GET /domains/{id} until active.Purchase
  • 400invalid_request or idempotency_key_required.
  • 401unauthorized: the key is missing, revoked or expired.
  • 402payment_required (no card, or an unresolved failed payment; details.reason and details.billingUrl say which) or payment_failed (the charge was declined).
  • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
  • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
  • 422idempotency_key_reuse: the key was used with a different request body.
  • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
post/domains/connect/preview

Preview connecting existing domains

Reads the current DNS and says what connecting would change. Limited to 30 calls per 10 minutes, shared with the dashboard.

Scopes:domains:write· 30 requests per minute

Parameters

  • Idempotency-Keyheader: string

    Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

Request body

    Responses

    • 200One item per name or zone.{ domains }
    • 400invalid_request or idempotency_key_required.
    • 401unauthorized: the key is missing, revoked or expired.
    • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
    • 422idempotency_key_reuse: the key was used with a different request body.
    • 424credential_invalid: the stored Cloudflare credential no longer works.
    • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
    post/domains/connect

    Connect existing domains

    Connects domains you already own. With names, point the nameservers at the ones yesboxes assigns: they arrive a few seconds after this call in ns.expected (GET /domains/{id}) and in the domain.connecting webhook. With mode: "cloudflare", yesboxes writes the records into your own Cloudflare zones. Needs a card on file. 20 names per hour and 10 pending domains per workspace, shared with the dashboard.

    Scopes:domains:write· 30 requests per minute

    Parameters

    • Idempotency-Keyheader: string

      Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

    Request body

      Responses

      • 201Connected domains, awaiting_nameservers until the nameservers match.{ domains }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 402payment_required (no card, or an unresolved failed payment; details.reason and details.billingUrl say which) or payment_failed (the charge was declined).
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 424credential_invalid: the stored Cloudflare credential no longer works.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/domains/{id}

      Get a domain

      Scopes:domains:read· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      Responses

      • 200The domain.DomainView
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      patch/domains/{id}

      Change domain settings

      Send only the fields to change. Unknown or mistyped fields are ignored.

      Scopes:domains:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      Request body

      • redirectUrlstring | null
      • redirectCheckboolean
      • replaceApexboolean
      • forwardTostring | null
      • catchAllMailboxIdstring | null
      • dmarcReportEmailstring | null

      Responses

      • 200The updated domain.DomainView
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      delete/domains/{id}

      Disconnect a domain or stop its renewal

      A connected domain is disconnected and its mailboxes cancelled. A purchased domain stops renewing; it is not refunded.

      Scopes:domains:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: stringrequired

        Required. Up to 255 characters. A retry with the same key and body replays the stored response for 24 hours (Idempotent-Replayed: true); a different body gives 422.

      Responses

      • 200The domain.DomainView
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/domains/{id}/check-nameservers

      Check nameservers now

      Re-checks the nameservers. The result is in ns of the returned domain. 1 call per minute per domain, shared with the dashboard.

      Scopes:domains:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Responses

      • 200The domain, with a fresh ns.DomainView
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/domains/{id}/rotate

      Move mailboxes to a replacement domain

      Scopes:domains:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Request body

      • replacementDomainIdstringrequired

      Responses

      • 202Rotation started.{ status }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).

      DNS

      Read and edit DNS records of a domain.

      get/domains/{id}/dns

      List DNS records

      Scopes:domains:read· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      Responses

      • 200Records, including those yesboxes manages.{ records }
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 424credential_invalid: the stored Cloudflare credential no longer works.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/domains/{id}/dns

      Add a DNS record

      Records yesboxes needs for mail (MX, SPF, DKIM, DMARC) cannot be overwritten: that gives 409 dns_rule.

      Scopes:domains:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Request body

      • typeA | AAAA | CNAME | TXT | MX | CAArequired
      • namestringrequired
      • contentstringrequired
      • ttlinteger
      • priorityinteger
      • proxiedboolean

      Responses

      • 201The record.{ record }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 424credential_invalid: the stored Cloudflare credential no longer works.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      patch/domains/{id}/dns/{recordId}

      Change a DNS record

      Scopes:domains:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • recordIdpath: stringrequired

        Resource id.

      Request body

      • typeA | AAAA | CNAME | TXT | MX | CAArequired
      • namestringrequired
      • contentstringrequired
      • ttlinteger
      • priorityinteger
      • proxiedboolean

      Responses

      • 200The record.{ record }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 424credential_invalid: the stored Cloudflare credential no longer works.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      delete/domains/{id}/dns/{recordId}

      Delete a DNS record

      Scopes:domains:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • recordIdpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Responses

      • 200Deleted.{ deleted }
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 424credential_invalid: the stored Cloudflare credential no longer works.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).

      Cloudflare

      Cloudflare connections for domains that stay in your own account.

      get/cloudflare-credentials

      List Cloudflare connections

      Scopes:domains:read· 600 requests per minute

      Responses

      • 200Connections. Secrets are never returned.{ credentials }
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/cloudflare-credentials

      Add a Cloudflare connection

      Write-only: the token or key is checked against Cloudflare and stored encrypted. 10 attempts per 10 minutes.

      Scopes:domains:write· 600 requests per minute

      Parameters

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Request body

      Option 1

      • labelstring
      • tokenstringrequired

      Option 2

      • labelstring
      • emailstringrequired
      • keystringrequired

        Global API key.

      Responses

      • 201The connection.CloudflareCredential
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/cloudflare-credentials/{id}/zones

      List zones of a connection

      Scopes:domains:read· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • pagequery: integer

        Starts at 1.

      • namequery: string

        Filter by zone name.

      Responses

      • 200Zones.{ zones, totalPages }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 424credential_invalid: the stored Cloudflare credential no longer works.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).

      Mailboxes

      Create, change and cancel mailboxes.

      post/domains/{id}/mailboxes

      Create mailboxes on a domain

      Up to 50 per call and 5 per domain. Mailboxes start pending and become active after provisioning. The monthly charge is asynchronous: it is prorated on the next invoice. Needs a card on file. A daily cap applies to new mailboxes. After a 5xx a retry can return 409 unavailable (already exists): list the domain's mailboxes.

      Scopes:mailboxes:writebilling:charge· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Required unless the body has dryRun: true. Up to 255 characters. A retry with the same key and body replays the stored response for 24 hours; a different body gives 422.

      Request body

      • mailboxesMailboxInput[]required
      • dryRunboolean

      Responses

      • 200Dry run: the monthly price change.{ quote }
      • 202Mailboxes created.{ mailboxes, warnings }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 402payment_required (no card, or an unresolved failed payment; details.reason and details.billingUrl say which) or payment_failed (the charge was declined).
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/mailboxes

      List mailboxes

      Scopes:mailboxes:read· 600 requests per minute

      Parameters

      • limitquery: integer

        Page size, 1 to 200. Default 50.

      • cursorquery: string

        Opaque cursor from nextCursor. A bad cursor gives 400.

      • domainIdquery: string
      • statusquery: pending | provisioning | active | paused | failed | cancelled
      • emailquery: string

        Substring of the address.

      Responses

      • 200A page of mailboxes.{ mailboxes, nextCursor }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/mailboxes/{id}

      Get a mailbox

      Scopes:mailboxes:read· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      Responses

      • 200The mailbox.MailboxView
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      patch/mailboxes/{id}

      Change a mailbox

      Changing localPart changes the address; that is asynchronous and returns 202.

      Scopes:mailboxes:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      Request body

      • firstNamestring
      • lastNamestring
      • localPartstring
      • signatureobject | null

      Responses

      • 200The updated mailbox.MailboxView
      • 202Address change started.MailboxView
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      delete/mailboxes/{id}

      Cancel a mailbox

      Scopes:mailboxes:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Responses

      • 200The mailbox, cancelled.MailboxView
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      put/mailboxes/{id}/forwarding

      Forward a mailbox

      Forwarding starts after the recipient confirms by email.

      Scopes:mailboxes:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      Request body

      • tostringrequired
      • keepCopyboolean

      Responses

      • 200The mailbox.MailboxView
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      delete/mailboxes/{id}/forwarding

      Stop forwarding

      Scopes:mailboxes:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Responses

      • 200The mailbox.MailboxView
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/mailboxes/{id}/schedule-removal

      Schedule removal

      Removes the mailbox shortly before the next invoice, so it is not billed again. Takes no body.

      Scopes:mailboxes:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Responses

      • 200The mailbox, with cancelAt set.MailboxView
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      delete/mailboxes/{id}/schedule-removal

      Cancel a scheduled removal

      Scopes:mailboxes:write· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Responses

      • 200The mailbox.MailboxView
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).

      Credentials

      SMTP and IMAP logins. These endpoints need the credentials:read scope.

      post/mailboxes/{id}/credentials

      Get a mailbox's login

      Call it after the mailbox is active. The response carries passwords: it sends cache-control: no-store, is never stored for idempotent replay, and is audit-logged with the key id and IP.

      Scopes:credentials:read· 60 requests per minute· never stored for replay

      Parameters

      • idpath: stringrequired

        Resource id.

      Responses

      • 200SMTP and IMAP login.Credentials
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/mailboxes/credentials

      Get logins for many mailboxes

      Send mailboxIds or domainId, up to 200 mailboxes. Mailboxes that are not active yet come back in notReady. The response carries passwords: it sends cache-control: no-store, is never stored for idempotent replay, and is audit-logged with the key id and IP.

      Scopes:credentials:read· 60 requests per minute· never stored for replay

      Request body

      • mailboxIdsstring[]

        Up to 200. Send this or domainId.

      • domainIdstring

      Responses

      • 200Logins.{ credentials, notReady }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/mailboxes/export

      Export logins as CSV

      Optionally limited to one domain. The response carries passwords: it sends cache-control: no-store, is never stored for idempotent replay, and is audit-logged with the key id and IP.

      Scopes:credentials:read· 60 requests per minute

      Parameters

      • domainIdquery: string

      Responses

      • 200CSV file.
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/mailboxes/{id}/reset-password

      Reset a mailbox password

      Issues a new password and returns it. A retried reset issues another password. The response carries passwords: it sends cache-control: no-store, is never stored for idempotent replay, and is audit-logged with the key id and IP.

      Scopes:credentials:readmailboxes:write· 60 requests per minute· never stored for replay

      Parameters

      • idpath: stringrequired

        Resource id.

      Responses

      • 200The new login.Credentials
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).

      Orders

      Domains plus mailboxes in one call.

      get/orders

      List orders

      Scopes:domains:read· 600 requests per minute

      Parameters

      • limitquery: integer

        Page size, 1 to 200. Default 50.

      • cursorquery: string

        Opaque cursor from nextCursor. A bad cursor gives 400.

      Responses

      • 200A page of orders.{ orders, nextCursor }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/orders

      Order domains with mailboxes

      Buys the domains, sets up DNS and creates the mailboxes, in one call. Needs a card on file (Settings, Billing in the dashboard); without one the call returns 402. A dry run needs no card. Needs the credentials:read scope as well when sequencerConnectionId is set. The key is bound to the order: a retry returns the same order, and the same key with different domains gives 422. A declined order frees the key. Poll GET /orders/{id} or listen for order.* webhooks. A daily cap applies to domain spend and to new mailboxes.

      Scopes:domains:writemailboxes:writebilling:charge· 30 requests per minute

      Parameters

      • Idempotency-Keyheader: string

        Required unless the body has dryRun: true. Up to 255 characters. A retry with the same key and body replays the stored response for 24 hours; a different body gives 422.

      Request body

      • domains{ name, redirectUrl }[]required

        1 to 50 domains.

      • mailboxesPerDomainintegerrequired

        1 to 5.

      • mailboxesMailboxInput[]

        One template applied to every domain. Must have exactly mailboxesPerDomain entries.

      • namingPattern{ names, style }
      • sequencerConnectionIdstring

        Export each domain's mailboxes to this connection when ready. Also needs the credentials:read scope.

      • maxTotalCentsinteger

        Refuse with 409 price_exceeded if the domains cost more.

      • dryRunboolean

        Return a quote and charge nothing.

      Responses

      • 200Dry run: the domain and mailbox quotes.{ quote }
      • 201Order created.OrderView
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 402payment_required (no card, or an unresolved failed payment; details.reason and details.billingUrl say which) or payment_failed (the charge was declined).
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/orders/{id}

      Get an order

      Scopes:domains:read· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      Responses

      • 200The order, with the state of each domain.OrderView
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).

      Sequencers

      Connect Smartlead, Instantly or SalesBlink and export mailboxes.

      get/sequencers

      List sequencer connections

      Scopes:sequencers· 600 requests per minute

      Responses

      • 200Connections.{ sequencers }
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/sequencers

      Connect a sequencer

      The API key is checked with the sequencer and stored encrypted. It is never returned.

      Scopes:sequencers· 600 requests per minute

      Parameters

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Request body

      • typesmartlead | instantly | salesblinkrequired
      • namestringrequired
      • apiKeystringrequired

      Responses

      • 201The connection.Sequencer
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      delete/sequencers/{id}

      Remove a sequencer connection

      Scopes:sequencers· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Responses

      • 204Removed.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/sequencers/{id}/exports

      Export mailboxes to a sequencer

      Sends mailbox logins to the sequencer. Poll GET /sequencer-exports/{id} for results. Audit-logged.

      Scopes:sequencerscredentials:read· 60 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Request body

      • mailboxIdsstring[]
      • domainIdstring
      • forceboolean

      Responses

      • 202Export started.SequencerExport
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/sequencer-exports/{id}

      Get an export

      Scopes:sequencers· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      Responses

      • 200The export.SequencerExport
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).

      Webhooks

      Signed event delivery.

      get/webhooks

      List webhook endpoints

      Scopes:webhooks· 600 requests per minute

      Responses

      • 200Endpoints.{ webhooks }
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/webhooks

      Add a webhook endpoint

      The signing secret is in the response and is shown once. Up to 10 endpoints.

      Scopes:webhooks· 600 requests per minute

      Parameters

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Request body

      • urlstringrequired

        https for public hosts.

      • events"all" | order.created | order.paid | order.payment_failed | order.completed | order.partially_failed | order.failed | domain.registering | domain.active | domain.failed | domain.refunded | domain.renewed | domain.expired | domain.connecting | domain.nameservers_matched | domain.active | domain.removed | domain.rotated | domain.moved | mailbox.provisioning | mailbox.active | mailbox.failed | mailbox.updated | mailbox.address_changed | mailbox.password_reset | mailbox.forwarding_changed | mailbox.removal_scheduled | mailbox.cancelled | mailbox.paused | mailbox.resumed | health.domain_blocklisted | health.domain_dns_drift | health.mailbox_bounce_rate_high | health.domain_bounce_rate | health.cloudflare_credential_invalid | health.recovered | billing.payment_failed | billing.payment_recovered[]

        Default "all".

      • descriptionstring

      Responses

      • 201The endpoint and its secret.WebhookWithSecret
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      patch/webhooks/{id}

      Change a webhook endpoint

      Scopes:webhooks· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      Request body

      • urlstringrequired

        https for public hosts.

      • events"all" | order.created | order.paid | order.payment_failed | order.completed | order.partially_failed | order.failed | domain.registering | domain.active | domain.failed | domain.refunded | domain.renewed | domain.expired | domain.connecting | domain.nameservers_matched | domain.active | domain.removed | domain.rotated | domain.moved | mailbox.provisioning | mailbox.active | mailbox.failed | mailbox.updated | mailbox.address_changed | mailbox.password_reset | mailbox.forwarding_changed | mailbox.removal_scheduled | mailbox.cancelled | mailbox.paused | mailbox.resumed | health.domain_blocklisted | health.domain_dns_drift | health.mailbox_bounce_rate_high | health.domain_bounce_rate | health.cloudflare_credential_invalid | health.recovered | billing.payment_failed | billing.payment_recovered[]

        Default "all".

      • descriptionstring

      Responses

      • 200The endpoint.Webhook
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      delete/webhooks/{id}

      Delete a webhook endpoint

      Scopes:webhooks· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Responses

      • 200Deleted.{ deleted }
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/webhooks/{id}/rotate-secret

      Rotate the signing secret

      Returns the new secret once.

      Scopes:webhooks· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Responses

      • 200The endpoint and its new secret.WebhookWithSecret
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/webhooks/{id}/deliveries

      List deliveries

      Scopes:webhooks· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • limitquery: integer

      Responses

      • 200Newest first.{ deliveries }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      post/webhook-deliveries/{id}/replay

      Replay a delivery

      Scopes:webhooks· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • Idempotency-Keyheader: string

        Up to 255 characters. Same key and same request replays the stored response for 24 hours (Idempotent-Replayed: true).

      Responses

      • 202Queued again.Delivery
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 409unavailable, conflict, locked, busy (retryable), dns_rule, request_in_progress, price_exceeded or already_created.
      • 422idempotency_key_reuse: the key was used with a different request body.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).

      Insights

      Sending statistics.

      get/insights

      Workspace insights

      Scopes:none· 600 requests per minute

      Parameters

      • rangequery: 24h | 7d | 30d | 90d
      • domainIdquery: string

      Responses

      • 200Summary.{ insights }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/insights/mailboxes

      Insights per mailbox

      Scopes:mailboxes:read· 600 requests per minute

      Parameters

      • rangequery: 24h | 7d | 30d | 90d
      • limitquery: integer

        Page size, 1 to 200. Default 50.

      • cursorquery: string

        Opaque cursor from nextCursor. A bad cursor gives 400.

      • sortquery: mailbox | health | sent | received | replyRate | bounceRate
      • dirquery: asc | desc

      Responses

      • 200A page of rows. next_cursor repeats nextCursor for older clients.{ mailboxes, nextCursor }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/mailboxes/{id}/insights

      Insights for one mailbox

      Scopes:mailboxes:read· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • rangequery: 24h | 7d | 30d | 90d

      Responses

      • 200Summary, daily series and provider breakdown.{ insights }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).
      get/mailboxes/{id}/bounces

      List a mailbox's bounces

      Scopes:mailboxes:read· 600 requests per minute

      Parameters

      • idpath: stringrequired

        Resource id.

      • rangequery: 24h | 7d | 30d | 90d
      • limitquery: integer

        Page size, 1 to 200. Default 50.

      • cursorquery: string

        Opaque cursor from nextCursor. A bad cursor gives 400.

      • typequery: hard | deferred

      Responses

      • 200A page of bounces.{ bounces, nextCursor }
      • 400invalid_request or idempotency_key_required.
      • 401unauthorized: the key is missing, revoked or expired.
      • 403forbidden (no route for API keys) or insufficient_scope (details.required lists the scopes).
      • 404not_found: the id does not exist in this workspace.
      • 429rate_limited (see Retry-After) or limit_exceeded (a daily cap; details has limit, used, requested and window).

      Docs

      The specification.

      get/openapi.json

      This specification

      Scopes:none

      Responses

      • 200OpenAPI 3.1 document.object

      Objects

      What comes back

      The main objects. Times are ISO 8601 strings, and null means not set.

      Error

      • error{ code, message, details }required

      OrderView

      • idstringrequired
      • statuspending_payment | payment_failed | processing | completed | partially_failed | failedrequired
      • totalCentsintegerrequired
      • createdAtstringrequired
      • domains{ domain, domainId, state, reason, mailboxes }[]required

      DomainView

      • idstringrequired
      • namestringrequired
      • tldstringrequired
      • statuspending_payment | registering | awaiting_nameservers | configuring_dns | active | failed | expired | removedrequired
      • lastErrorstring | nullrequired
      • refundDuebooleanrequired
      • refundedbooleanrequired
      • priceCentsinteger | nullrequired

        First-year price in cents. Null for connected domains.

      • redirectUrlstring | nullrequired
      • expiresAtstring | nullrequired
      • dnsExpectedDnsRecord[]required
      • dnsLastCheckstring | nullrequired
      • createdAtstringrequired
      • sourcepurchased | connectedrequired
      • dnsModeours | user_cfrequired
      • cfCredentialIdstring | nullrequired
      • ns{ expected, observed, status, lastCheckAt, matchedAt }required
      • settings{ redirectCheck, forward, catchAllMailboxId, dmarcRua }required
      • spfValuestring | nullrequired
      • dmarcManagedbooleanrequired
      • willNotRenewbooleanrequired
      • mxReplaceConfirmedAtstring | nullrequired
      • rotationobject | nullrequired
      • sendingPausedKindblocklist | bounce_rate | nullrequired

      MailboxView

      • idstringrequired
      • domainIdstringrequired
      • emailstringrequired
      • firstNamestringrequired
      • lastNamestringrequired
      • displayNamestringrequired
      • statuspending | provisioning | active | paused | failed | cancelledrequired
      • failureReasonstring | nullrequired
      • createdAtstringrequired
      • signatureobject | nullrequired
      • cancelAtstring | nullrequired
      • passwordResetAtstring | nullrequired
      • forwardobject | nullrequired
      • previousEmails{ email, until }[]required
      • addressChangeobject | nullrequired
      • sendCap{ perDay, step, steps }required

      Credentials

      • emailstringrequired
      • usernamestringrequired
      • passwordstringrequired

        Shown by this call only; never stored for replay.

      • smtp{ host, sslPort, starttlsPort }required
      • imap{ host, port }required
      • pausedbooleanrequired

        Billing paused this mailbox; the password works again once payment is fixed.

      ConnectPreviewItem

      • namestringrequired
      • zoneIdstring | nullrequired
      • problemobject | nullrequired
      • canChallengebooleanrequired

        An ownership challenge is available in the dashboard.

      • mxstring[]required
      • spfstring | nullrequired
      • spfAfterstring | nullrequired
      • dmarcstring | nullrequired
      • dmarcKeptbooleanrequired
      • copy{ key, type, name, content, priority, ttl }[]required

        Existing records to copy into the new zone.

      Webhook

      • idstringrequired
      • urlstringrequired
      • events"all" | order.created | order.paid | order.payment_failed | order.completed | order.partially_failed | order.failed | domain.registering | domain.active | domain.failed | domain.refunded | domain.renewed | domain.expired | domain.connecting | domain.nameservers_matched | domain.active | domain.removed | domain.rotated | domain.moved | mailbox.provisioning | mailbox.active | mailbox.failed | mailbox.updated | mailbox.address_changed | mailbox.password_reset | mailbox.forwarding_changed | mailbox.removal_scheduled | mailbox.cancelled | mailbox.paused | mailbox.resumed | health.domain_blocklisted | health.domain_dns_drift | health.mailbox_bounce_rate_high | health.domain_bounce_rate | health.cloudflare_credential_invalid | health.recovered | billing.payment_failed | billing.payment_recovered[]required
      • descriptionstring | nullrequired
      • secretHintstringrequired
      • createdAtstringrequired

      Delivery

      • idstringrequired
      • endpointIdstringrequired
      • eventIdstringrequired
      • typeorder.created | order.paid | order.payment_failed | order.completed | order.partially_failed | order.failed | domain.registering | domain.active | domain.failed | domain.refunded | domain.renewed | domain.expired | domain.connecting | domain.nameservers_matched | domain.active | domain.removed | domain.rotated | domain.moved | mailbox.provisioning | mailbox.active | mailbox.failed | mailbox.updated | mailbox.address_changed | mailbox.password_reset | mailbox.forwarding_changed | mailbox.removal_scheduled | mailbox.cancelled | mailbox.paused | mailbox.resumed | health.domain_blocklisted | health.domain_dns_drift | health.mailbox_bounce_rate_high | health.domain_bounce_rate | health.cloudflare_credential_invalid | health.recovered | billing.payment_failed | billing.payment_recoveredrequired
      • statusstringrequired
      • attempts{ n, at, statusCode, latencyMs, body, error, replay }[]required
      • nextAttemptAtstring | nullrequired
      • createdAtstringrequired

      Create a key and place an order

      Add a card under Settings, then Billing, before the first purchase.