AgentBIT
← all tools

DNS Inspector

DNS inspection for agents auditing infrastructure, deliverability and counterparties. One call resolves all the record types that matter (A, AAAA, MX, TXT, NS, CNAME, SOA, CAA — or the subset you ask for) through Cloudflare's public DNS-over-HTTPS resolver, returning each record with its TTL. On top of the raw records it computes an email security posture: SPF record present and its all-policy (~all vs -all), DMARC record fetched from _dmarc.<domain> with its p= policy, MX count, and a one-word assessment (enforced / monitoring-only / partial / unprotected). CAA records show which CAs may issue certificates. Use it before trusting mail from a domain, when diagnosing deliverability, or as the DNS layer of a counterparty check alongside domain-intel and counterparty-risk.

$0.01
USDC per call · x402
Endpoint
POST /v1/dns/inspect
MCP name
agentbit.dns_inspect
Status
active
Latency / uptime (7d)
284 ms · 100%

Call with x402

1. Send the request. 2. Receive 402 with accepts[]. 3. Sign the payment and retry with the X-PAYMENT header.

curl -X POST https://agentbit.app/v1/dns/inspect \
  -H 'Content-Type: application/json' \
  -d '{"domain":"example.com","types":["A","MX","TXT"]}'

Input schema

{
    "type": "object",
    "properties": {
        "domain": {
            "type": "string",
            "description": "Hostname to inspect, e.g. example.com"
        },
        "types": {
            "type": "array",
            "items": {
                "type": "string",
                "enum": [
                    "A",
                    "AAAA",
                    "MX",
                    "TXT",
                    "NS",
                    "CNAME",
                    "SOA",
                    "CAA"
                ]
            },
            "description": "Record types to query (default: all eight)"
        }
    },
    "required": [
        "domain"
    ]
}

Output schema

{
    "type": "object",
    "properties": {
        "domain": {
            "type": "string"
        },
        "records": {
            "type": "object",
            "description": "Records grouped by type: [{name, ttl, data}]"
        },
        "email_posture": {
            "type": [
                "object",
                "null"
            ],
            "properties": {
                "spf_present": {
                    "type": "boolean"
                },
                "spf_policy": {
                    "type": [
                        "string",
                        "null"
                    ]
                },
                "dmarc_present": {
                    "type": "boolean"
                },
                "dmarc_policy": {
                    "type": [
                        "string",
                        "null"
                    ]
                },
                "mx_count": {
                    "type": "integer"
                },
                "assessment": {
                    "type": "string",
                    "enum": [
                        "enforced",
                        "monitoring-only",
                        "partial",
                        "unprotected"
                    ]
                }
            }
        },
        "resolved": {
            "type": "boolean"
        }
    }
}

Code examples

// JavaScript (x402-fetch)
import { wrapFetchWithPayment } from "x402-fetch";
const fetchWithPay = wrapFetchWithPayment(fetch, wallet);
const r = await fetchWithPay("https://agentbit.app/v1/dns/inspect", {
  method: "POST",
  headers: {"Content-Type": "application/json"},
  body: JSON.stringify({"domain":"example.com","types":["A","MX","TXT"]})
});
console.log(await r.json());
# Python (x402 client)
from x402.clients.requests import x402_requests
s = x402_requests(account)
r = s.post("https://agentbit.app/v1/dns/inspect",
  json={"domain":"example.com","types":["A","MX","TXT"]})
print(r.json())
// PHP
$r = Http::withHeaders(['X-PAYMENT' => $signedPayment])
  ->post('https://agentbit.app/v1/dns/inspect',
    array (
  'domain' => 'example.com',
  'types' => 
  array (
    0 => 'A',
    1 => 'MX',
    2 => 'TXT',
  ),
));
$data = $r->json();