Criar domínio
POST /v1/domains
Exemplo de requisição
curl -X POST "https://app.madmail.com.br/api/v1/domains" \
-H "Authorization: Bearer us_SUA_CHAVE" \
-H "Content-Type: application/json" \
-d '{
"name": "Exemplo",
"region": "string"
}'Corpo da requisição
| Campo | Tipo | Obrigatório | Descrição |
|---|---|---|---|
name | string | Sim | |
region | string | Sim |
Exemplo
{
"name": "Exemplo",
"region": "string"
}Respostas
200 — Cria um novo domínio
| Campo | Tipo | Descrição |
|---|---|---|
id | number | ID do domínio |
name | string | Nome do domínio |
teamId | number | ID do workspace |
status | string | |
region | string | |
clickTracking | boolean | |
openTracking | boolean | |
publicKey | string | |
dkimStatus | string | null | |
spfDetails | string | null | |
createdAt | string | |
updatedAt | string | |
dmarcAdded | boolean | |
isVerifying | boolean | |
errorMessage | string | null | |
subdomain | string | null | |
verificationError | string | null | |
lastCheckedTime | string | null | |
dnsRecords | array<object> |
Exemplo de resposta
{
"id": 1,
"name": "example.com",
"teamId": 1,
"status": "NOT_STARTED",
"publicKey": "string",
"createdAt": "string",
"updatedAt": "string",
"dnsRecords": [
{
"type": "TXT",
"name": "mail",
"value": "v=spf1 include:amazonses.com ~all",
"ttl": "Auto",
"status": "NOT_STARTED"
}
]
}