Re-enable a disabled domain
const url = 'https://api.nsin.ir/domains/example.com/enable';const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.nsin.ir/domains/example.com/enable \ --header 'Authorization: Bearer <token>'Brings a disabled domain back into service. A managed domain returns to
pending and is re-checked against the NSIN nameservers. Requires
domain.settings.
Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ”The domain name (for example example.com) — not a numeric id.
Example
example.comResponses
Section titled “ Responses ”Domain re-enabled.
object
pending— managed domain waiting for its nameservers to point at NSIN.unverified— external-DNS domain waiting for its TXT verification record.active— serving.moved— delegation has left NSIN; the domain keeps serving during a grace window.disabled— not serving; re-enable withPOST /domains/{domain}/enable.banned— administratively blocked.
managed — NSIN hosts the DNS zone. external — you host DNS
elsewhere and prove ownership with a TXT record.
Id of the owning user.
Per-domain cap on disk (L2) cache size, in GB.
How long a disk-cache entry may live, in days. Maximum 7.
Largest response body NSIN will buffer and cache, in MB. Bigger responses stream straight from origin and are never cached. The selectable ceiling depends on the domain’s plan.
While set and in the future, the edge bypasses cache reads and writes for this domain. Absent when developer mode is off.
When the background nameserver checker will next look at this domain.
Last user-triggered nameserver check; these are limited to one per hour.
Send X-Content-Type-Options: nosniff. Off by default — it can break
an origin that mislabels asset MIME types.
Send Referrer-Policy: strict-origin-when-cross-origin.
Strip origin fingerprint headers from responses.
Serve a Markdown rendering of eligible HTML pages to clients sending
Accept: text/markdown. Requires an active plan.
Notify the owner when a subdomain suffers a sustained origin outage.
Per-minute origin-error percentage that counts as “down”.
Minutes the domain must stay down before an incident opens.
Minimum origin-eligible requests in the window — the traffic floor below which no incident opens.
Minimum populated one-minute buckets required in the window.
Consecutive clear minutes before an incident resolves.
Paused for billing. The edge refuses the domain’s TLS handshake, so visitors get a connection error. Clears automatically once the wallet is no longer negative.
The TXT record to publish to prove ownership of an external-DNS domain.
object
Name to create the TXT record at.
Exact TXT value to publish.
The canonical (first) accepted nameserver set.
Every accepted nameserver set. The delegation must match exactly one set in full — sets cannot be mixed.
The nameservers currently observed in the parent zone.
Your role on a domain. owner is implicit for the domain’s creator and
for global admins; the other three are grantable via sharing.
How often the background checker re-checks the delegation.
Example
{ "name": "example.com", "status": "pending", "dns_mode": "managed", "cache_cap_mb": 128, "verification": { "type": "TXT" }, "my_role": "owner", "my_permissions": [ "domain.view" ]}The domain is not in the disabled state.
The single error shape used by every endpoint.
object
Human-readable description of what went wrong.
Example
{ "error": "read-only API key"}Missing, malformed, revoked or expired API key — or the owning account is inactive.
The single error shape used by every endpoint.
object
Human-readable description of what went wrong.
Examples
{ "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.
The single error shape used by every endpoint.
object
Human-readable description of what went wrong.
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.
The single error shape used by every endpoint.
object
Human-readable description of what went wrong.
Example
{ "error": "read-only API key"}The key exceeded its request budget (300 requests per minute by default).
The single error shape used by every endpoint.
object
Human-readable description of what went wrong.
Examples
{ "error": "rate limit exceeded"}