Read SAML Metadata Now

POST /v1/endpoints/{uuid}/saml/idps/{idp_uuid}/refresh

Read a SAML IdP's metadata URL now, for example after the IdP published a new signing certificate. ngris also reads it every day. At most once a minute per IdP. A read that fails keeps the last values working and is shown on the IdP (metadata_error). Metadata that was pasted doesn't update itself: send the new one with Update SAML IdP. In the dashboard: Read now on the IdP's row.

Needs the endpoint_saml feature on the plan of the account that owns the endpoint (Enterprise) and the endpoints:update permission. No request body.

Path parameters

uuid string (uuid) Req
The endpoint's uuid from /endpoints.
idp_uuid string (uuid) Req
The IdP's uuid from List SAML IdPs.

An integer id in the path is refused with 400 integer_id_unsupported (see public IDs). Use the uuid.

Response (200 OK)

The IdP, as Get SAML IdP answers it, with the new metadata_read_at. When the certificates changed, certs_changed_at says so.

Errors

401 Unauthorized
Missing auth.
403 Forbidden
Caller lacks the endpoints:update permission, or the plan doesn't include SAML single sign-on ("entitlement_required": "endpoint_saml").
404 Not Found
Endpoint doesn't exist or doesn't belong to the calling account, or the IdP isn't this endpoint's (SAML IdP not found).
409 Conflict
The metadata was pasted (This IdP's metadata was pasted: it doesn't update itself. Paste the new metadata with PUT, or give its URL.); the metadata now names another IdP (The metadata now names another IdP (…). Check it, and add that IdP as a new one if it's right.); the endpoint has no address yet, or it is paused.
429 Too Many Requests
The metadata was read less than a minute ago. Try again in a minute.
502 Bad Gateway
The URL couldn't be read, or its metadata can't be used, with why. The last values keep working.
503 Service Unavailable
SAML single sign-on isn't available yet. Try again in a few minutes.
Request
curl -X POST "https://api.ngris.com/v1/endpoints/019bb1e4-e785-77d2-9966-c3cff31d0a0e/saml/idps/019c6a2e-4b10-7c3d-9e21-5a7f0b8c1d23/refresh" \ -H "X-API-KEY: <your_api_key>"
CLI
ngris api saml-idps refresh 019bb1e4-e785-77d2-9966-c3cff31d0a0e 019c6a2e-4b10-7c3d-9e21-5a7f0b8c1d23
Response — 502 (the URL didn't answer)
{ "error": "The metadata URL couldn't be read. It must be https, on a public address, answer 200 within 15 seconds and not redirect. Paste the metadata instead if your IdP is only reachable inside your network." }
Was this helpful?
On this page
Read SAML Metadata Now
Was this helpful?