Skip to main content

Rotate Issued API Key

POST 

/v2alpha1/admin/issuedApiKeys/:key_id:rotate

Generates a new secret for an issued API key. Creates a new API key with a new key_id and secret, and immediately revokes the old key. This is the recommended way to update scopes, metadata, or rotate credentials.

For zero-downtime rotation, use this workflow instead:

  1. IssueAPIKey with new credentials
  2. Deploy new secret to all services
  3. Verify new secret works everywhere
  4. RevokeAPIKey to remove the old key

Request

Responses

A successful response.