Domains and deliverability

Add and verify a domain, manage suppression and inbound receiving.

Sending is only allowed from a verified domain.

Add the domain

POST /api/v1/domains returns the DNS records to publish.

Publish the DNS records

SPF, DKIM and MAIL FROM at your DNS provider.

Verify

POST /api/v1/domains/:id/verify checks SPF, DKIM and DMARC.

With the SDK

// 1. Add the domain (the DNS records come back in `dnsRecords`)
const { id, dnsRecords } = await sending.domains.create({ name: "yourdomain.dev" });
 
// 2. Publish the records at your DNS provider, then verify
await sending.domains.verify(id);
 
// 3. (optional) Enable inbound receiving for Agent Email
await sending.domains.enableInbound(id);

Sender name

By default the recipient only sees the address: from [email protected] Gmail shows "hello". Set a sender name on the domain and email goes out as Federico <[email protected]>.

It applies to every email sent from an address on that domain: transactional, campaigns and automations. If the send already specifies a full sender (from: "Marketing <[email protected]>") that wins over the domain default. In the dashboard: Communication › Domains › detail › Sender tab.

await sending.domains.update(id, { defaultFromName: "Federico" });
 
// Remove the default (back to the bare address)
await sending.domains.update(id, { defaultFromName: null });

An agent can do the same over MCP with set_domain_sender_name, and read the current value with list_domains.

Suppression

Addresses that hard-bounced, complained or unsubscribed land in the suppression list, and sends towards them are blocked automatically.

Inbound receiving

Enable receiving (MX) for a domain with POST /api/v1/domains/:id/inbound, to run Agent Email on a domain of your own.