Skip to content

WHOIS lookup for domain/IP/ASN

GET
/whois
const url = 'https://api.dazrik.net/whois?target=example.com';
const options = {method: 'GET'};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}

Returns registration data for a domain, public IP address, or ASN such as AS15169. Hostnames are reduced to their registrable domain, so www.example.com looks up example.com. The fields in data depend on the target type. Unavailable fields are omitted, and registrant details are included only when disclosed.

target
required
string

Domain/hostname, IP address, or ASN (e.g. ‘AS15169’).

Example

example.com

Registration data for the target type

Media typeapplication/json
object
ok
required
boolean
query
required
string
data
required
Any of:

Domain registration data. All fields are optional; unavailable or undisclosed fields are omitted.

object
domainName
string
registryDomainId
string
registrar
string
registrarIanaId
string
registrarUrl
string
registrarWhoisServer
string
whoisServer
string
registrarAbuseContactEmail
string
registrarAbuseContactPhone
string
registrantName
string
registrantOrganization
string
registrantState
string
registrantCountry
string
registrantEmail
string
createdDate

Registration creation date, in ISO 8601 when available; otherwise the reported date string

string
updatedDate

Last registration update, in ISO 8601 when available; otherwise the reported date string

string
expiryDate

Registration expiry date, in ISO 8601 when available; otherwise the reported date string

string
domainStatus
Array<string>
nameServer
Array<string>
dnssec
string

Example

{
"ok": true,
"query": "example.com",
"data": {
"domainName": "EXAMPLE.COM",
"domainStatus": [
"clientTransferProhibited"
],
"dnssec": "signedDelegation"
}
}
RateLimit
string

Request budget for the current window: limit, remaining, and reset (seconds until the window resets). Returned by known GET endpoints.

Example
limit=60, remaining=59, reset=42
RateLimit-Limit
integer

Maximum requests allowed per client IP per window (60 requests per 60s).

Example
60
RateLimit-Remaining
integer

Requests remaining in the current window before the limit is hit.

Example
59
RateLimit-Reset
integer

Seconds until the current window resets.

Example
42

Missing or invalid parameter

Media typeapplication/json

Error response.

object
ok
required
boolean
msg
required
string

Example

{
"ok": false,
"msg": "query param target is required"
}
RateLimit
string

Request budget for the current window: limit, remaining, and reset (seconds until the window resets). Returned by known GET endpoints.

Example
limit=60, remaining=59, reset=42
RateLimit-Limit
integer

Maximum requests allowed per client IP per window (60 requests per 60s).

Example
60
RateLimit-Remaining
integer

Requests remaining in the current window before the limit is hit.

Example
59
RateLimit-Reset
integer

Seconds until the current window resets.

Example
42

Target resolves to a private/reserved address

Media typeapplication/json

Error response.

object
ok
required
boolean
msg
required
string

Example

{
"ok": false,
"msg": "target doesn't resolve to a public addr"
}
RateLimit
string

Request budget for the current window: limit, remaining, and reset (seconds until the window resets). Returned by known GET endpoints.

Example
limit=60, remaining=59, reset=42
RateLimit-Limit
integer

Maximum requests allowed per client IP per window (60 requests per 60s).

Example
60
RateLimit-Remaining
integer

Requests remaining in the current window before the limit is hit.

Example
59
RateLimit-Reset
integer

Seconds until the current window resets.

Example
42

The request limit of 60 requests per minute per client IP was reached, or /connect or /website requests to the same destination are temporarily limited. The per-client request limit includes Retry-After, the number of seconds until the request budget resets. Destination-limit responses omit that header. A destination limit can apply even when RateLimit-Remaining is greater than zero.

Media typeapplication/json

Error response.

object
ok
required
boolean
msg
required
string

Example

{
"ok": false,
"msg": "you're being rate limited, try again later."
}
RateLimit
string

Request budget for the current window: limit, remaining, and reset (seconds until the window resets). Returned by known GET endpoints.

Example
limit=60, remaining=59, reset=42
RateLimit-Limit
integer

Maximum requests allowed per client IP per window (60 requests per 60s).

Example
60
RateLimit-Remaining
integer

Requests remaining in the current window before the limit is hit.

Example
59
RateLimit-Reset
integer

Seconds until the current window resets.

Example
42
Retry-After
integer

Seconds to wait before retrying after the per-client request limit is reached. Destination connection limits can return HTTP 429 without this header.

Example
42

Lookup failed

Media typeapplication/json
object
ok
required
boolean
msg
required
string
query
string

Example

{
"ok": false,
"query": "example.com",
"msg": "couldn't get whois info"
}
RateLimit
string

Request budget for the current window: limit, remaining, and reset (seconds until the window resets). Returned by known GET endpoints.

Example
limit=60, remaining=59, reset=42
RateLimit-Limit
integer

Maximum requests allowed per client IP per window (60 requests per 60s).

Example
60
RateLimit-Remaining
integer

Requests remaining in the current window before the limit is hit.

Example
59
RateLimit-Reset
integer

Seconds until the current window resets.

Example
42