domain
DNS concepts

DNS records

Supported record types, validated fields, and safe intent examples.

Pass between 1 and 100 records in intent.records. The SDK validates every record locally before sending it to Domain0.

const { connection } = await platform.createConnection({
  intent: {
    domain: 'customer.example',
    records: [
      { host: '@', type: 'A', value: '192.0.2.10', ttl: 300 },
      { host: 'www', type: 'CNAME', value: 'edge.example.net', ttl: 300 },
    ],
  },
})

Supported types

TypeValueNotes
AIPv4 addressExample: 192.0.2.10
AAAAIPv6 addressExample: 2001:db8::10
CNAMEDomain nameDo not combine with other data at the same name
CAAFlags, tag, and valueExample: 0 issue "letsencrypt.org"
MXMail-server domainRequires priority
TXTText valueMust not contain NUL characters or newlines
NSNameserver domainUse only when your product intentionally delegates DNS

Fields

FieldRequiredBehavior
hostYes@ or a relative DNS name; a leading wildcard is supported
typeYesOne of the supported record types above
valueYesValidated according to type
ttlNoInteger in seconds; defaults to 300
priorityMX onlyInteger from 0 to 65535
optionalNoDefaults to false; optional failures do not block required records

Records come from trusted product data

Build the intent from your product configuration or database. Do not accept arbitrary records from an untrusted browser request.

Common examples

[
  { host: '@', type: 'A', value: '192.0.2.10', ttl: 300 },
  { host: 'www', type: 'CNAME', value: 'edge.example.net', ttl: 300 },
]

Existing-record validation

Use the optional policy only when an existing valid DMARC or CAA record can satisfy your product requirement:

await platform.createConnection({
  intent: {
    domain: 'customer.example',
    existingRecordPolicy: {
      validateDmarc: true,
      validateCAA: true,
    },
    records,
  },
})

Both switches default to false. Domain0 shows and verifies the resolved effective intent, which may contain fewer records than the original request.

On this page