Domains

You send from domains you own. Adding one generates a unique record set; publishing it and passing verification flips the domain to active.

Domain, mailbox, and webhook management is done in the dashboard, which is session-authenticated (not via an API key). This page documents what those endpoints return so you know exactly which DNS records to publish and what “verified” means. The hosting-oriented walkthrough, with registrar tips, lives on the DNS setup page.

Add a domain

Adding a domain (POST /domains) creates it in pending status and returns the DNS records to publish. A DKIM key pair is generated for the domain shortly after, adding its record to the set. An optional catch_all_target forwards mail sent to any unmatched address on the domain.

json
// POST /domains  →  201
{
  "domain": {
    "id": "…",
    "domain": "yourco.com",
    "status": "pending",
    "is_send_enabled": true,
    "is_receive_enabled": true,
    "verified_at": null
  },
  "dns_records": [ /* the records below */ ]
}

DNS records

Publish these at your DNS host, exactly as given. Substitute your own domain for yourco.com; the verification token and DKIM selector are unique to your domain (copy them from the dashboard).

TypeNameValuePurpose
MXyourco.com10 mx1.mail.atrix.dev.Routes inbound mail to us.
TXTyourco.comv=spf1 include:mail.atrix.dev ~allSPF — authorises our servers to send for you.
TXT_atrixmail.yourco.comatrix-mail-verify=<token>Ownership verification.
TXT<selector>._domainkey.yourco.comYour DKIM public keyDKIM — cryptographically signs outbound mail.
TXT_dmarc.yourco.comv=DMARC1; p=none; rua=mailto:dmarc@mail.atrix.devDMARC policy + aggregate reports.

Recommended (not required for activation) — MTA-STS and TLS-RPT enforce TLS on inbound mail to your domain and collect TLS reports:

TypeNameValue
CNAMEmta-sts.yourco.commta-sts.mail.atrix.dev.
TXT_mta-sts.yourco.comv=STSv1; id=atrixmail1
TXT_smtp._tls.yourco.comv=TLSRPTv1; rua=mailto:tls-reports@mail.atrix.dev
Sending requires SPF and DKIM to pass; inbound mail flows once MX verifies. DMARC starts at p=none so nothing is quarantined while you confirm alignment — tighten it to quarantine or reject at your registrar once reports look clean.

Verify

Verification runs automatically every few minutes. To trigger an immediate re-check, call POST /domains/:id/verify (rate limited to once per 30 seconds per domain). Each record moves from pending to ok (or mismatch) as it propagates; the domain flips to active when the required records pass. A domain.verified webhook fires when it does.

You can check propagation yourself:

shell
dig MX yourco.com +short
# expect: 10 mx1.mail.atrix.dev.

dig TXT yourco.com +short
# expect a line containing: v=spf1 include:mail.atrix.dev ~all

Health grade

GET /domains/:id/health returns the record set plus a grade summarising deliverability posture:

GradeMeaning
excellentEvery record verified.
goodMX and DKIM verified; some optional records still pending.
issuesAt least one published record does not match what we expect.
pendingNothing has verified yet.

Endpoints

MethodPathPurpose
POST/domainsAdd a domain; returns the DNS records.
GET/domainsList your domains.
GET/domains/:idOne domain and its records.
GET/domains/:id/healthRecords + deliverability grade.
POST/domains/:id/verifyRequest an immediate re-check.
DELETE/domains/:idRemove a domain (delete its mailboxes first).
These endpoints authenticate with a dashboard session, not an am_live_ API key. The API-key surface is sending only — see Authentication.