Set Active Certificate

PUT /v1/domains/self/{uuid}/active-cert

Switch which previously-issued certificate is currently being served for the domain. Most users never need this — the platform automatically picks the freshest valid cert and renews ahead of expiry. Use this only when:

  • A new cert was issued but you want to keep serving the old one for HPKP pinning compatibility.
  • A new cert has a problem (wrong SANs, etc.) and you need to roll back to the previous one.
  • You issued a custom cert manually and want to make it active explicitly.

The change takes effect on the next TLS handshake at the edge — typically < 1 second after this call returns. Existing connections continue with their previously-negotiated cert until they reconnect.

Path parameters

uuid string (uuid) Req
The domain's uuid from /domains/available.

Request body

certificate_uuid string (uuid) Req
The uuid of a certificate of this domain, from /certificates. It must belong to this domain.

Response (200 OK)

ok boolean
true on success.
message string
Human-readable confirmation.
domain_status string?
active when choosing the certificate finished a manual-mode domain that was waiting for one. Omitted otherwise.

Errors

400 Bad Request
Missing certificate_uuid, or the certificate belongs to a different domain.
401 Unauthorized
Missing auth.
404 Not Found
Domain or certificate doesn't exist, or the domain belongs to another account.
Request
curl -X PUT "https://api.ngris.com/v1/domains/self/019bd08f-98db-71b2-8e54-f518d319f111/active-cert" \ -H "X-API-KEY: <your_api_key>" \ -H "Content-Type: application/json" \ -d '{"certificate_uuid": "019be236-c4fb-72c2-b153-1eefef23705b"}'
Python
from ngris import Ngris client = Ngris(api_key="<your_api_key>") client._put_raw( "/domains/self/019bd08f-98db-71b2-8e54-f518d319f111/active-cert", {"certificate_uuid": "019be236-c4fb-72c2-b153-1eefef23705b"}, )
Response — 200 OK
{ "ok": true, "message": "Active certificate updated." }
Was this helpful?
On this page
Set Active Certificate
Was this helpful?