Add a sending domain
POST/v1/sending-domains
Requires an API key with the domains:write scope. About keys and scopes
Works with integration, agent and partner keys.
A repeat after success is refused with 409 ALREADY_EXISTS: read the one the first created. About idempotency
Registers a domain to send from and returns the DNS records to publish, all at once. It cannot send until they are in place and status is verified; Kirora checks them in the background, or call POST /v1/sending-domains/{id}/check. A Unicode domain is stored and returned in its punycode form (münchen.de becomes xn--mnchen-3ya.de); an IP address, a numeric top-level domain or invalid punycode is refused, as are a public suffix (co.uk) and a public mailbox domain or its subdomains (gmail.com), since neither can be verified. A removed domain can be added again.
Header parameters
Kirora-WorkspacestringoptionalPartner keys only: the child workspace to act in, by the external id the partner gave it. Without it, a partner key acts in its own workspace. Any other key that sends it is refused with 403, and an unknown workspace is 404.
pattern
^[A-Za-z0-9._:-]{1,128}$Idempotency-KeystringoptionalMakes a retry safe: a repeat with the same key and body within 24 hours gets the first response again, with
Idempotency-Replay: true. The same key with another request is 409IDEMPOTENCY_KEY_REUSED; while the first is still running, 409IDEMPOTENCY_KEY_IN_USE; after anunsafefirst request failed or never returned, 409IDEMPOTENCY_KEY_OUTCOME_UNKNOWN. Use a new key, such as a UUID, for each new request.8–255 characters
Request body
domainstringrequiredThe domain to send from, such as
mail.example.com. A Unicode name is stored in its punycode form.up to 253 characters
Returns
Returns 201 Created with a SendingDomain in data. It can also return 409 Conflict, 413 Payload Too Large or 415 Unsupported Media Type; see the statuses below. Otherwise returns an error; Errors lists every code and which to retry.
201 CreatedThe new domain, with the DNS records to publish.409 ConflictThe request conflicts with current state — a duplicate unique value, or a resource whose status does not allow this operation.413 Payload Too LargeThe body is larger than this operation accepts (PAYLOAD_TOO_LARGE).415 Unsupported Media TypeThe body is not JSON, or not the upload the operation takes (UNSUPPORTED_MEDIA_TYPE).
idstringrequireduuid
domainstringrequiredstatusstringrequiredWhether the domain can send:
pendinguntil its DNS records are all found;awaiting_review, you own it but a person at Kirora has not cleared it to send yet, and it is set up the moment they do (reviewsays more);verified, it can send;verification_lost, it was verified but a record has since gone missing, and nothing sends from it until the record is back;failed, seefailureReason;quarantined, the domain is already set up by another account, so nothing sends from it until Kirora support reviews it.one of
pending,awaiting_review,verified,verification_lost,failed,quarantinedfailureReasonstring | nullrequiredWhy verification failed, when it has.
lastCheckedAtstring | nullrequiredWhen DNS was last checked.
date-time
dnsRecordsSendingDomainDnsRecord[]requiredThe records to publish at your DNS host, the ownership record first.
7 child attributes
purposestringrequiredownership: proves you control the domain, and holds the key that signs its mail;dkim: another signing key record;mailFrom: thebounce.subdomain that receives bounces and aligns SPF.one of
ownership,dkim,mailFromtypestringrequiredone of
CNAME,TXT,MXnamestringrequiredThe full hostname to publish the record at.
hoststringrequiredThe name without the registered domain, which most DNS hosts ask for, since they add the domain themselves:
sel._domainkeyforsel._domainkey.example.com,@for the domain itself.valuestringrequiredWhat the record must contain.
matchesbooleanrequiredWhether the last check found the record as given.
reasonstring | nullrequiredWhy it does not match, such as what DNS holds there; null when it does.
checksobjectrequiredEach check's state, for showing progress;
statusis what decides.5 child attributes
ownershipstringrequiredWhether proof that you control the domain has been found in DNS.
one of
pending,verifieddkimstringrequiredThe DKIM signing records.
one of
pending,verified,failedmailFromstringrequiredThe
bounce.(MAIL FROM) records.one of
pending,verified,faileddmarcobject | nullrequiredThe DMARC record covering the domain, which marketing email needs; null before the first check.
4 child attributes
statusstringrequiredWhether a usable DMARC record was found.
one of
valid,missing,invalid,unknownpolicystring | nullrequiredThe policy the DMARC record sets.
one of
none,quarantine,rejectpolicyDomainstring | nullrequiredThe domain the DMARC record was found on.
inheritedbooleanrequiredTrue when the record is the parent domain's, not the domain's own.
bimiobject | nullrequiredBIMI, for the brand's logo beside its email: guidance, never a requirement. Mailboxes show it only with DMARC at
quarantineorreject. Null until a check reads it.3 child attributes
statusstringrequiredWhether
default._bimi.<domain>holds a BIMI record.one of
present,missing,unknownlogoUrlstring | nullrequiredIts logo (
l=): an SVG Tiny PS file over HTTPS.certificateUrlstring | nullrequiredIts mark certificate (
a=, a VMC or CMC), which Gmail and Apple Mail need before showing the logo; Yahoo can show it without one.
reviewobjectrequiredIts sending review (
SENDING_REVIEW_REQUIRED).2 child attributes
statusstringrequiredWhether a person at Kirora has cleared the domain to send; until then it has no provider identity (
statusisawaiting_reviewonce you own it), and nothing sends from it, not even a test.not_requested: proven yours, waiting for the workspace's sending profile (website, what it sends, how contacts agreed), which asks for review once filled in.in_review: waiting for a person, usually within a day. A subdomain of an approved domain is approved when proven.one of
not_requested,in_review,approved,declineddeclineReasonstring | nullrequiredWhy it was declined; null unless
declined.
createdAtstringrequireddate-time
updatedAtstringrequireddate-time
Headers on 201 Created
Idempotency-Replaystringoptionaltruewhen this is the stored response to an earlier request with the same key.one of
true