Domain WHOIS (RDAP)
POST /api/whoisDomain registration data via RDAP (the structured WHOIS successor): registrar, creation/expiry dates, status, nameservers. Send POST /api/whois with the required field domain and pay $0.005 per call over x402 or MPP (there is no free tier). It returns a JSON object with domain, registrar, created, expires, nameservers and 1 more.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
domain | string | yes | Domain name (registrable, e.g. example.com) Also accepted as host, hostname, site. |
Example request
curl -i -X POST https://agent402.tools/api/whois \
-H "Content-Type: application/json" \
-d '{"domain":"example.com"}'
Without payment this returns HTTP 402 Payment Required with the exact price for whois; any x402 v2 or MPP client pays it and retries.
Example response
{
"domain": "example.com",
"registrar": "IANA",
"created": "1995-08-14",
"expires": "2026-08-13",
"nameservers": [
"a.iana-servers.net"
],
"status": [
"client transfer prohibited"
]
}
| Field | Type | Always present | In the example |
|---|---|---|---|
domain | string | yes | example.com |
registrar | string | yes | IANA |
created | string | yes | 1995-08-14 |
expires | string | yes | 2026-08-13 |
nameservers | array of string | yes | 1 item in the example |
status | array of string | yes | 1 item in the example |
From an MCP client
catalog.call {
"slug": "whois",
"params": {
"domain": "example.com"
}
}
The hosted connector at https://agent402.tools/mcp needs a payment for whois; the stdio package pays it from a wallet or from AGENT402_CREDITS_KEY. Local install: npx -y agent402-mcp.
Errors and behavior
domainis required. An input the tool rejects returns an HTTP 4xx whose body carrieserror,tool,expected,requiredandexample, so the caller can correct it.- A paid call that ends in any status of 400 or above is not charged over x402, MPP or a prepaid credits key: settlement is cancelled when the tool fails. The exception is a Tempo push credential, a transfer the buyer sent before the call: it settles before the tool runs, so if the tool then fails the payment is recorded as a refund owed to the paying wallet.
- Wallet-only: this tool reaches the network or stored state, so it has no proof-of-work tier. A prepaid card-credits key issued earlier (
Authorization: Bearer a402_...) also pays it. - A
GETorHEADto /api/whois returns the same 402 quote, so the price can be read without a body. - An
Idempotency-Keyheader makes a retried paid call replay the first 200 instead of charging again (an answer larger than 1 MB is not replayed).
Paid call (JavaScript agent)
import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
const client = new x402Client();
client.setSpendControls?.(false); // keep your own spending ceiling in code
registerExactEvmScheme(client, { signer: privateKeyToAccount(KEY) });
const payFetch = wrapFetchWithPayment(fetch, client);
const res = await payFetch("https://agent402.tools/api/whois", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"domain": "example.com"
}),
});
Part of these workflows
Domain WHOIS (RDAP) is one step in these 7 skill packs, each sold as a single call:
- DNS & network ops - End-to-end DNS health check: records, multi-resolver propagation, WHOIS, ASN, robots.txt, and reachability.
- Fraud signals - Is this domain trustworthy, or is it a phishing site / typosquat / scam? Pull the reputation signals an analyst checks before clicking anything: domain age, cert issuance history, hosting reputation, DNS topology, tech-stack fingerprint, and page-content red flags. Different from a security audit - this is about whether the domain is what it claims to be.
- Domain intel - Full domain security and SEO intelligence in one call: WHOIS, DNS, TLS cert, HTTP headers, tech stack, robots policy, and certificate transparency.
- Brand protection - Is this domain legitimate? WHOIS age, DNS resolution, scam/phishing search results, and HTTP headers for a quick trust assessment.
- Competitor scan - What's a competitor using? Tech stack, HTTP headers, WHOIS, and page metadata in one call.
- Domain age and legitimacy - How old and legit is this domain? WHOIS registration, DNS resolution, and TLS certificate in one pass.
- Entity enrichment - Company name → verified identity + web footprint dossier: Wikidata facts, the official LEI legal-entity record, the SEC EDGAR filer, domain registration, tech stack, and brand favicon - in one pass.
Related tools
A2A Agent Card fetch
POST /api/a2a-card-fetchDiscover and fetch a site's A2A (Agent2Agent protocol) Agent Card - tries /.well-known/agent-card.json then /.well-known…
ASN + IP geolocation
POST /api/asn-infoLook up the Autonomous System (ASN), prefix, country, registry, and allocation date for an IPv4 address - or for a hostn…
Certificate transparency search
POST /api/cert-transparencySearch public Certificate Transparency logs for every cert issued to a domain. Two independent public CT search services…
DKIM key lookup
POST /api/dkim-lookupFetch and parse a DKIM public-key record at <selector>._domainkey.<domain> (RFC 6376). Returns the parsed key params (al…
DMARC check
POST /api/dmarc-checkFetch and validate a domain's DMARC policy at _dmarc.<domain> (RFC 7489). Surfaces the enforcement policy (none/quaranti…
DNS lookup
GET /api/dnsLive DNS lookup for a domain: returns name, type and records[]. Supported record types: A, AAAA (addresses as strings), …