DNS records for a domain with TXT-based service hints.
GET/dns_lookup/{domain}
- Takes: Domain
- Passive: the target is not contacted
- Cost: 1 credit
Refuses special-use names, IPs, URLs and ports; internationalised names must use the xn-- form. An empty array means no records of that type; null means the lookup failed. A 404 or 502 also costs 1 credit.
Path parameters
domainPublic domain, at most 253 bytes, at least two labels
Response fields · 9ShowHide
domain
Lower-case domain
a[]
A records
mx[]
MX records with priority and host
ns[]
Name servers
txt[]
TXT records
unavailable[]
Record types whose lookup failed, with reasons
name
Service whose verification word appears in a TXT record
summary
Text count of each record type
remaining
Credits left in the window
curl 'https://api.contrastcyber.com/dns_lookup/example.com' \
-H 'X-API-Key: YOUR_API_KEY'{
"domain": "example.com",
"records": {
"a": [
"203.0.113.7"
],
"mx": [
{
"priority": 10,
"host": "mail.example.com"
}
],
"ns": [
"ns1.example.com"
],
"txt": [
"v=spf1 -all"
]
},
"unavailable": [],
"services": [],
"summary": "1 A, 1 MX, 1 NS, 1 TXT",
"credits": {
"charged": 1,
"remaining": 29
}
}