A fleet API key's rotation report
const url = 'https://example.com/api/nss/keys/example/rotation-report?format=csv';const options = {method: 'GET', headers: {'X-Ssoossh-Key-Secret': '<X-Ssoossh-Key-Secret>'}};
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://example.com/api/nss/keys/example/rotation-report?format=csv' \ --header 'X-Ssoossh-Key-Secret: <X-Ssoossh-Key-Secret>'Per source address, whether it has switched to the current secret since the last rotation: switched, not_switched (still presenting the previous secret, so it resolves no new accounts when the grace ends) or gone (not seen since the rotation). With format=csv the rows come as a CSV download instead. Whoever may view the key.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Key id
Query Parameters
Section titled “Query Parameters”Csv for a CSV download
Responses
Section titled “Responses”The report
object
object
GraceDaysLeft is whole days, rounded up, until the previous secret stops working; zero when there is none or it has ended.
object
Bucket is switched (last presented the current secret), not_switched (last presented an older one) or gone (not seen since the rotation).
An unknown format
object
Data is always null on an error response.
Error is a human-readable message. Branch on the HTTP status rather than this string; it is for humans and logs.
Example
certificate request "9f1c…" not foundErrorCode is a machine-readable error classifier. One of the error_code constants from internal/apitypes; use this to decide whether to retry or branch on the failure mode.
Example
not_foundNo valid session
object
Data is always null on an error response.
Error is a human-readable message. Branch on the HTTP status rather than this string; it is for humans and logs.
Example
certificate request "9f1c…" not foundErrorCode is a machine-readable error classifier. One of the error_code constants from internal/apitypes; use this to decide whether to retry or branch on the failure mode.
Example
not_foundNo such key the caller may view, or nss_disabled
object
Data is always null on an error response.
Error is a human-readable message. Branch on the HTTP status rather than this string; it is for humans and logs.
Example
certificate request "9f1c…" not foundErrorCode is a machine-readable error classifier. One of the error_code constants from internal/apitypes; use this to decide whether to retry or branch on the failure mode.
Example
not_found