Probe which HTTP versions the origins speak
const url = 'https://api.nsin.ir/domains/example.com/origin-protocols';const options = {method: 'GET', 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 GET \ --url https://api.nsin.ir/domains/example.com/origin-protocols \ --header 'Authorization: Bearer <token>'Makes a TLS handshake (reading the ALPN answer), a QUIC handshake and one
HEAD / request (reading the Alt-Svc header) against every distinct
origin behind the domain’s proxied records, from the NSIN control plane,
and reports whether each speaks HTTP/1.1, HTTP/2 and HTTP/3. HTTP/3
counts as supported when either the QUIC handshake completed or the
origin advertised h3 in Alt-Svc; http3_via says which. Use it
before changing origin_protocol. Answers younger than 20 seconds are
reused, so repeated calls do not hammer the origin. Requires domain.view.
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 ”Per-origin protocol support.
What a domain’s origins speak, from a TLS handshake (ALPN), a QUIC
handshake and one HEAD / request (for Alt-Svc) made from the NSIN
control plane. A result proves the origin speaks a protocol; whether
UDP is open on the path from a given edge is decided at the edge, which
falls back to TCP per origin.
object
The domain’s current origin_protocol setting.
One entry per distinct origin (destination, port, scheme) across the domain’s proxied records. Gateway records are excluded.
object
The server name presented in the handshake.
false for a plain-HTTP origin, which can only be HTTP/1.1.
How HTTP/3 support was established. Absent when http3 is false.
Why the TCP/TLS handshake failed
Why the QUIC handshake failed. Absent when it succeeded. Present
next to http3_via = alt-svc when the origin advertises HTTP/3
but the control plane could not reach it over UDP.
Whether EVERY TLS origin answered the protocol.
object
The highest protocol every origin supports.
Example
{ "current": "http1", "origins": [ { "http3_via": "quic" } ], "recommended": "http1", "probed_from": "control plane"}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"}