Skip to main content
POST
/
v1
/
domains
Add domain
curl --request POST \
  --url https://api.emailr.dev/v1/domains \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "domain": "example.com",
  "receivingSubdomain": "mail"
}
'
{
  "id": "123e4567-e89b-12d3-a456-426614174000",
  "organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "domain": "<string>",
  "status": "verified",
  "verification_token": "<string>",
  "dkim_verified": true,
  "spf_verified": true,
  "dmarc_verified": true,
  "cloudflare_zone_id": "<string>",
  "ses_identity_arn": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "verified_at": "2023-11-07T05:31:56Z",
  "dkim_tokens": [
    "<string>"
  ],
  "dns_records": {
    "dkim": {
      "type": "TXT",
      "name": "<string>",
      "value": "<string>",
      "priority": 123
    },
    "spf": {
      "type": "TXT",
      "name": "<string>",
      "value": "<string>",
      "priority": 123
    },
    "dmarc": {
      "type": "TXT",
      "name": "<string>",
      "value": "<string>",
      "priority": 123
    },
    "mailFromMx": {
      "type": "TXT",
      "name": "<string>",
      "value": "<string>",
      "priority": 123
    },
    "mailFromSpf": {
      "type": "TXT",
      "name": "<string>",
      "value": "<string>",
      "priority": 123
    },
    "receivingMx": {
      "type": "TXT",
      "name": "<string>",
      "value": "<string>",
      "priority": 123
    }
  },
  "dkim_selector": "<string>",
  "mail_from_subdomain": "<string>",
  "mail_from_verified": true,
  "receiving_enabled": true,
  "receiving_subdomain": "<string>"
}

Authorizations

Authorization
string
header
required

API key authentication. Use your API key as the bearer token.

Body

application/json
domain
string
required
Minimum string length: 1
Example:

"example.com"

receivingSubdomain
string
default:mail
Example:

"mail"

Response

Domain added

id
string<uuid>
required
Example:

"123e4567-e89b-12d3-a456-426614174000"

organization_id
string<uuid>
required
domain
string
required
status
string
required
Example:

"verified"

verification_token
string | null
required
dkim_verified
boolean
required
spf_verified
boolean
required
dmarc_verified
boolean
required
cloudflare_zone_id
string | null
required
ses_identity_arn
string | null
required
created_at
string<date-time>
required
verified_at
string<date-time> | null
required
dkim_tokens
string[] | null
required
dns_records
object
required
dkim_selector
string | null
required
mail_from_subdomain
string | null
required
mail_from_verified
boolean | null
required
receiving_enabled
boolean | null
required
receiving_subdomain
string | null
required