Domain registry records and status, DNS records, and IP/ASN resolution over RDAP and DoH.
Runs on your machine from its package; the steps are below.
At most: only reads or looks up information.
Odel charges nothing per call. The publisher may charge for its own service.
Runs locally over stdio
This server isn't hosted — your MCP client launches it from a package registry. Use one of the commands below, or drop the config into your client (e.g. Claude Desktop).
Run
npx -y @cyanheads/whois-mcp-server
MCP client config
{
"mcpServers": {
"whois": {
"command": "npx",
"args": [
"-y",
"@cyanheads/whois-mcp-server"
]
}
}
}Run
npx -y @cyanheads/whois-mcp-server
MCP client config
{
"mcpServers": {
"whois": {
"command": "npx",
"args": [
"-y",
"@cyanheads/whois-mcp-server"
]
}
}
}Look up domain registration, check registry record status, fetch DNS records, and resolve IPs and ASNs over RDAP and DNS-over-HTTPS via MCP. STDIO or Streamable HTTP.
Domain and network intelligence via RDAP and DNS-over-HTTPS. Look up domain registrations, check registry record status, fetch DNS records, and resolve IPs and ASNs to their registries. No API key required.
| Tool | Description |
|---|---|
whois_lookup_domain | Full domain registration record — registrar, created/expiry dates, nameservers, EPP status, DNSSEC, registrant org |
whois_check_availability | Check registry record presence; missing records do not establish registration eligibility |
whois_get_dns | DNS owner records via DNS-over-HTTPS (A, AAAA, MX, TXT, NS, CNAME, SOA, CAA, PTR) |
whois_lookup_ip | IP or CIDR netblock, org, country, abuse contact, and reverse DNS via RIR RDAP |
whois_lookup_asn | Resolve an ASN to its org name, country, and RIR source |
whois_get_dossier | One-call domain triage — registration + DNS in parallel, normalized into a single record with factual signals |
whois_lookup_domain toolregistrant_redacted; DNSSEC and privacy stay null when the registry gives no evidence. Fails with rdap_no_coverage, domain_not_found, or rdap_invalid_domain_response (the response doesn't match the queried domain).include_registrar: true follows one registrar RDAP referral and adds registrar_detail (found, no_referral, or failed, plus source URL). Off by default; limited by RDAP_TIMEOUT_MS, and a failure keeps the registry result.whois_check_availability toolregistration_status: registered | not_found | unknown. available is false for a found registration and null otherwise, never true: a 404 means no record, not that the name can be registered.non_registrable_domain with their registrable parent.whois_get_dns tool_dmarc.example.com are fine), up to 253 characters with 1–63-character labels. Optional types: A, AAAA, MX, TXT, NS, CNAME, SOA, CAA, PTR; defaults to A, AAAA, MX, TXT, NS.query_sources: [{type, source}], including empty answers and NXDOMAIN. Legacy source is cloudflare if any query got a successful Cloudflare response, otherwise nextdns.whois_lookup_ip toolip.cidrs (cidr only when there is exactly one), and a best-effort reverse DNS lookup: ptr_status: found | not_found | failed, with ptr_source_error on failure while the RDAP data is kept.include_routing: true adds routing (found | not_found | failed) with the RIS-observed prefix and origin_asns, from RIPEstat Network Info. Off by default; a routing failure keeps the RDAP and PTR results.invalid_ip, ip_not_found, ip_no_rdap_route (no RIR covers the address; not retryable), or private_range for 0.0.0.0/8, 10.0.0.0/8, 100.64.0.0/10, 127.0.0.0/8, 169.254.0.0/16, 172.16.0.0/12, 192.168.0.0/16, 255.0.0.0/8, ::1/128, fc00::/7, and fe80::/10.whois_lookup_asn toolAS prefix (e.g., AS15169, AS 15169, +15169). Out-of-range numbers fail with invalid_asn.name, org_name, country, rir, start_autnum, and end_autnum; fails with asn_not_found when no record exists.whois_get_dossier toolrdap_source_error or dns_source_error; both_legs_failed means neither succeeded.0 .) means the domain accepts no mail.Built on @cyanheads/mcp-ts-core: stdio and Streamable HTTP transports, pluggable auth (none / jwt / oauth), swappable storage (in-memory, filesystem, Supabase, Cloudflare KV/R2/D1), structured logging with optional OpenTelemetry tracing.
RDAP / DNS-specific:
Agent-friendly output:
rdap_coverage: false returned as data by whois_check_availability and whois_get_dossier, while whois_lookup_domain throws rdap_no_coverage for the same casetrue when the registry shows it and null when there's no evidencewhois_get_dossier marks a failed lookup with a source_error field and continues; only both failing is an errorage_days, privacy_redacted, ns_provider, mx_provider are real data, not synthesized risk scoresNo API keys or accounts required. Add the following to your MCP client configuration file.
{
"mcpServers": {
"whois-mcp-server": {
"type": "stdio",
"command": "bunx",
"args": ["@cyanheads/whois-mcp-server@latest"],
"env": {
"MCP_TRANSPORT_TYPE": "stdio",
"MCP_LOG_LEVEL": "info"
}
}
}
}
Or with npx (no Bun required):
{
"mcpServers": {
"whois-mcp-server": {
"type": "stdio",
"command": "npx",
"args": ["-y", "@cyanheads/whois-mcp-server@latest"],
"env": {
"MCP_TRANSPORT_TYPE": "stdio",
"MCP_LOG_LEVEL": "info"
}
}
}
}
Or with Docker:
{
"mcpServers": {
"whois-mcp-server": {
"type": "stdio",
"command": "docker",
"args": [
"run", "-i", "--rm",
"-e", "MCP_TRANSPORT_TYPE=stdio",
"ghcr.io/cyanheads/whois-mcp-server:latest"
]
}
}
}
For Streamable HTTP, set the transport and start the server:
MCP_TRANSPORT_TYPE=http MCP_HTTP_PORT=3010 bun run start:http
# Server listens at http://127.0.0.1:3010/mcp
git clone https://github.com/cyanheads/whois-mcp-server.git
cd whois-mcp-server
bun install
cp .env.example .env
# All vars are optional — defaults work for most use cases
| Variable | Description | Default |
|---|---|---|
RDAP_TIMEOUT_MS | HTTP timeout for RDAP requests in milliseconds. | 5000 |
DOH_TIMEOUT_MS | HTTP timeout for DNS-over-HTTPS requests in milliseconds. | 3000 |
RDAP_MAX_RETRIES | Max retry attempts on transient RDAP failures. | 2 |
DOH_MAX_RETRIES | Max retry attempts on transient DoH failures. | 2 |
MCP_TRANSPORT_TYPE | Transport: stdio or http. | stdio |
MCP_HTTP_PORT | Port for HTTP server. | 3010 |
MCP_AUTH_MODE | Auth mode: none, jwt, or oauth. | none |
MCP_LOG_LEVEL | Log level (RFC 5424). | info |
OTEL_ENABLED | Enable OpenTelemetry instrumentation. | false |
See .env.example for the full list of optional overrides.
Build and run:
bun run rebuild
bun run start:stdio
# or
bun run start:http
Run checks and tests:
bun run devcheck # Lint, format, typecheck, security
bun run test # Vitest test suite
bun run lint:mcp # Validate MCP definitions against spec
docker build -t whois-mcp-server .
docker run --rm -p 3010:3010 whois-mcp-server
The Dockerfile defaults to HTTP transport, stateless session mode, and logs to /var/log/whois-mcp-server. OpenTelemetry peer dependencies are installed by default — build with --build-arg OTEL_ENABLED=false to omit them.
| Path | Purpose |
|---|---|
src/index.ts | Entry point — starts the app. |
src/app.ts | createApp() options — registers tools, inits services, declares the session mode. |
src/config/ | Server-specific environment variable parsing and validation (Zod). |
src/services/rdap/ | RDAP client — IANA bootstrap cache, domain/IP/ASN lookup, retry. |
src/services/doh/ | DNS-over-HTTPS client — Cloudflare primary, NextDNS fallback. |
src/services/routing/ | Optional RIPEstat RIS routing observations with a bounded exchange. |
src/mcp-server/tools/ | Tool definitions (*.tool.ts). |
tests/ | Vitest tests mirroring src/. |
docs/ | Design and API reference documents. |
See CLAUDE.md for development guidelines and architectural rules. The short version:
try/catch in tool logicctx.log for request-scoped loggingsrc/app.ts's tools arrayIssues are welcome. Run checks and tests before submitting:
bun run devcheck
bun run test
Apache-2.0 — see LICENSE for details.