Skip to content

Add an email domain

View .md
POST

Add a domain to send email from. Returns the DNS records to publish (DKIM CNAMEs are required; SPF, DMARC, and MAIL FROM are recommended). Publish them at your DNS provider, then verify.

Authorization

  • Authorizationheaderrequired

    Bearer YOUR_API_KEY. Create a key in the dashboard.

Body

application/json

  • domainstringrequired

    Bare domain, e.g. example.com.

Responses

201Domain added.
  • domainobjectrequired
    5 properties
    • idstringrequired
    • domainstringrequired
    • statusstringrequired

      Overall verification status.

    • dkimStatusstringrequired
    • dnsRecordsobject[]

      DNS records to publish. Present when fetching a single domain or after adding one.

      6 properties
      • typestringrequired

        DNS record type.

      • namestringrequired

        Record host/name to create.

      • valuestringrequired

        Record value.

      • priorityinteger

        Priority (MX records only).

      • purposestringrequired

        What the record is for. ownership is a TXT at _zavu-verification.<domain>, returned only when another Zavu account also added this domain and neither has verified it: DKIM records are the same for everyone, so the domain verifies only once this account's own token is published.

        One ofdkimspfdmarcmail_fromownership
      • requiredbooleanrequired

        Whether the record is required to verify + send (DKIM) or recommended for deliverability.

400Invalid domain or setup failed.
  • codestringrequired
  • messagestringrequired
  • detailsobject
401Unauthorized.
  • codestringrequired
  • messagestringrequired
  • detailsobject
409`domain_taken`: another Zavu account has already verified this domain. A sending domain belongs to one account; if it is yours, contact support.
  • codestringrequired
  • messagestringrequired
  • detailsobject