This function checks whether the local server is authoritative for the domain's DNS records.
uapi --output=jsonpretty \ --user=username \ DNS \ has_local_authority \ domain='example.com'
{- "apiversion": 3,
- "func": "has_local_authority",
- "module": "DNS",
- "result": {
- "data": [
- {
- "domain": "example.com",
- "local_authority": 1,
- "nameservers": [
- "ns1.example.com",
- "ns2.example.com"
], - "zone": "example.com"
}, - {
- "domain": "example2.com",
- "local_authority": 0,
- "nameservers": [ ]
}, - {
- "domain": "example3.com",
- "error": "(XID 3z756a) DNS query (example3.com/SOA) timeout!",
- "local_authority": 0,
- "nameservers": [ ],
- "zone": "example3.com"
}
], - "errors": null,
- "messages": null,
- "metadata": {
- "transformed": 1
}, - "status": 1,
- "warnings": null
}
}