Skip to content
nsin docs

Check nameserver delegation now

POST
/domains/{domain}/check-ns
curl --request POST \
--url https://api.nsin.ir/domains/example.com/check-ns \
--header 'Authorization: Bearer <token>'

Runs an immediate delegation check for a pending or moved managed domain instead of waiting for the background checker. On success the domain is activated right away, and the zone’s apex NS records are aligned with the delegation. The outcome is also stored as the ns entry of GET /domains/{domain}/checks.

Rate-limited to once per hour per domain, independently of the API key rate limit; the attempt counts even when the lookup fails. Requires domain.settings.

domain
required
string

The domain name (for example example.com) — not a numeric id.

Example
example.com

Check result.

Media type application/json
object
ok

Whether the delegation is acceptable: every NSIN node named, nothing foreign.

boolean
status
  • pending — waiting to be activated: a managed domain for its nameservers to point at NSIN (disabled after 28 days without that), an external-DNS domain for its verification record (3-day window).
  • failed — an external-DNS domain whose 3-day verification window ran out. Start a new window with POST /domains/{domain}/verify/retry.
  • active — serving.
  • moved — was active, but the delegation (managed) or the verification record (external) is gone. The domain keeps serving for a 3-day grace window, then is disabled; putting it back reactivates it at the next check.
  • disabled — not serving: zone removed, records un-proxied, cache purged. Re-enable with POST /domains/{domain}/enable.
  • banned — administratively blocked.
string
Allowed values: pending failed active moved disabled banned
message
string
next_check_at
string format: date-time
nsin_ns

The nameservers the delegation is expected to match.

Array<string>
current_ns

The nameservers actually observed.

Array<string>
Example
{
"status": "pending"
}

Returned instead of the inline verdict to callers that are not API keys (the panel, an NSIN SSO access token): the check keeps running in the background — it can take up to a minute — and its result is read from GET /domains/{domain}/checks. A second call while one is running returns the running job. The body may carry the endpoint’s own extra fields (for example next_check_at).

Media type application/json
object
checking
boolean
check

One manual check and its last outcome.

object
kind

Which check: ns delegation, txt verification, dv SSL delegation, edge proxied-record reachability, email_dns Email Routing records.

string
Allowed values: ns txt dv edge email_dns
state

running — the check is in flight; poll again. done — it completed and ok carries the verdict. error — it could not reach an answer (a resolver was unreachable). An error is never a verdict about the domain’s DNS.

string
Allowed values: running done error
ok

The verdict of a done check.

boolean
message

What to show the user.

string
started_at

When the check started.

string format: date-time
finished_at

When it finished. Absent while running.

string format: date-time
message

What to show the user while the check runs.

string
key
additional properties
any
Example
{
"checking": true,
"check": {
"kind": "ns",
"state": "running"
}
}

Not a managed domain, or the domain is not awaiting nameserver changes.

Media type application/json

The single error shape used by every endpoint.

object
error
required

Human-readable description of what went wrong.

string
Example
{
"error": "read-only API key"
}

Missing, malformed, revoked or expired API key. (A valid key whose account has been deactivated gets 403 account is inactive instead.)

Media type application/json

The single error shape used by every endpoint.

object
error
required

Human-readable description of what went wrong.

string
Examples
Example invalidKey
{
"error": "invalid API key"
}

The key is read-only, your role on the domain lacks the required permission, or the domain’s plan does not include the feature.

Media type application/json

The single error shape used by every endpoint.

object
error
required

Human-readable description of what went wrong.

string
Example
{
"error": "read-only API key"
}

No such domain, or it is not visible to this account. Domains you cannot access are reported as not found rather than forbidden.

Media type application/json

The single error shape used by every endpoint.

object
error
required

Human-readable description of what went wrong.

string
Example
{
"error": "read-only API key"
}

Either the once-per-hour manual check limit (next_check_at says when the next one is allowed) or the API key rate limit was hit.

Media type application/json
object
error
required

Human-readable description of what went wrong.

string
next_check_at
string format: date-time
Examples
Example hourly
{
"error": "You can check NS once per hour",
"next_check_at": "2026-09-28T12:00:00Z"
}