Rotate an API key
Issue a fresh token and invalidate every previous one, in a single call. Also the only way to see a token after creation.
Rotate is also the recovery path
Cadenya never shows a token after the response that minted it. Lost the value? There is nothing to look up, only this call: rotate, capturespec.token, and move on. That is the “lose it, rotate it” rule from the API key model.
Related
Create an API key
Disable an API key
Rotate the global API key
Update an API key
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The workspace the API key belongs to (path).
"workspace_01HXKD2E5NQM3T9AYWCF133E3Q"
The API key to rotate. A new token is issued and any existing token is invalidated.
"apikey_01HXKD2E5NQM3T9AYWCFCSPNQY"
Body
The body is of type object.
Response
OK
An API key. Every key belongs to exactly one workspace and is managed via the workspace-scoped API key routes. The only exception is the system-managed global account key, which spans all workspaces and is managed via the account global_api_key routes.
AccountResourceMetadata is used to represent a resource that is associated to an account but not to a workspace.
Configuration for an API key.
The current lifecycle state of the API key. Output only. Keys are created STATE_ENABLED; use the :disable and :enable actions to transition between states.
STATE_UNSPECIFIED, STATE_ENABLED, STATE_DISABLED