POST /api/v1/generate/{kind}
Pure record builders, no DNS queries. Warnings and errors are returned as structured, machine-readable codes (for example “too-many-lookups”), never as display text; this is intentional so integrations can localize them.
Name
Type
Required
Description
kind
string
yes
—
Plus the fields of one of these variants:
Variant
Fields
SpfGenerateInput
allowA: boolean, allowMx: boolean, ip4: string[], ip6: string[], includes: string[], all: string
DmarcGenerateInput
policy: string, subdomainPolicy: string, rua: string[], ruf: string[], pct: integer, adkim: string, aspf: string, fo: string, domain: string
CaaGenerateInput
issue: string[], issuewild: string[], iodef: string, critical: boolean
MtaStsGenerateInput
domain: string, mode: string, mx: string[], maxAgeDays: integer, id: string, tlsRptEmail: string
Status
Type
Description
200
SpfGenerateResult | DmarcGenerateResult | CaaGenerateResult | MtaStsGenerateResult
Generated record(s), shape depends on kind
400
object
Error
405
object
Error
429
object
Error
Field
Type
Required
Description
api
string
no
—
kind
string
no
—
warnings
IssueCode []
no
—
Plus the fields of one of these variants:
Variant
Fields
SpfGenerateResult
host: string, type: string, record: string, lookupCount: integer, errors: IssueCode []
DmarcGenerateResult
host: string, type: string, record: string, errors: IssueCode []
CaaGenerateResult
records: GeneratedRecord []
MtaStsGenerateResult
dnsRecord: GeneratedRecord , policyFile: string, policyUrl: string, tlsRptRecord: GeneratedRecord
curl -X POST " https://dns-doctor.com/api/v1/generate/<kind> " \
-H " Authorization: Bearer $REGFISH_API_KEY " \
-H " Content-Type: application/json " \
Fill in values — the call below updates as you type. Nothing is sent: the API does not currently allow browser requests from this domain (CORS). The API key is not stored.