Domains
Add Domain
Add a new domain to your account. DKIM keys are generated automatically and the domain goes through security screening.
https://graph.sendcorex.com/v3.0/domainsBefore the domain is added it is checked against blocklists and for phishing. Domains with forbidden names or TLDs, or that are blacklisted, are rejected with BLACKLISTED.
Body parameters
domainNamestringrequiredThe domain name to add.
e.g.
"sendcorex.com"
Quick start
import axios from 'axios';
const response = await axios.post(
'https://graph.sendcorex.com/v3.0/domains',
{
domainName: "sendcorex.com"
},
{ headers: { Authorization: process.env.SENDCOREX_API_KEY } },
);
console.log(response.data);Response
{
"success": true,
"code": "DOMAIN_ADDED",
"domain": {
"domain": "sendcorex.com",
"validated": false,
"hasMx": false,
"hasDkim": false,
"hasDmarc": false,
"hasPath": false,
"hasSpf": false,
"createdAt": "2026-07-14T10:00:00.000Z",
"updatedAt": "2026-07-14T10:00:00.000Z",
"registrar": "Cloudflare",
"dnsRecords": {
"spf": {
"host": "sendcorex.com",
"value": "v=spf1 include:smtp.emailsbit.com ~all",
"type": "TXT"
},
"dkim": {
"host": "selector._domainkey.sendcorex.com",
"value": "v=DKIM1; k=rsa; p=...",
"type": "TXT"
},
"mx": {
"host": "sendcorex.com",
"value": "bounce.emailsbit.com",
"type": "MX",
"priority": 0
},
"returnPath": {
"host": "bounces.sendcorex.com",
"value": "bounce.emailsbit.com",
"type": "CNAME"
},
"dmarc": {
"host": "_dmarc.sendcorex.com",
"value": "v=DMARC1; p=none; rua=mailto:dmarc@bounces.sendcorex.com",
"type": "TXT"
}
}
},
"responseTime": "1245ms"
}Response fields
codeDOMAIN_ADDEDwhen the domain was added.domain.domainThe domain name.
domain.validatedfalseuntil the DNS records are in place and verified.domain.has*Which DNS records were found. All
falseright after adding.domain.registrarThe DNS provider detected for the domain.
domain.dnsRecordsThe records to add at your DNS provider. See below.
DNS records
Add these records at your DNS provider. The has* flags tell you which ones were found.
dnsRecords.spfTXT record that authorizes Sendcorex to send for your domain.
dnsRecords.dkimTXT record with the DKIM public key, generated for your domain.
dnsRecords.mxMX record. It points to
bounce.emailsbit.comand is the one that lets you receive emails.dnsRecords.returnPathCNAME record for the return path, used for bounces.
dnsRecords.dmarcTXT record with your DMARC policy and the address that receives reports.
Each record has host, value and type. The MX record also has priority.
Errors
HTTP-level errors return type, code and message. Errors marked CMD come back inside the command result, with HTTP 200.
- 401
INVALID_API_KEYThe API key is invalid or revoked.
- 400
BLACKLISTEDThe domain was rejected for security reasons: forbidden name, TLD or blacklisted domain.