api-keys

Rotate Api Key

Rotate a key: mint a new one with the same name + scopes + rate limits, soft-revoke the old one. Returns the NEW full key (shown once).

Use this when a key may have been leaked or as part of regular hygiene. The new key takes effect immediately; the old key is dead immediately (no overlap window — clients should swap atomically).

post/api/v1/api-keys/{key_id}/rotate

Request

  • Base URL: https://api.badgeia.com
  • URL: https://api.badgeia.com/api/v1/api-keys/{key_id}/rotate
  • Auth: none declared

Path parameters

key_idstring uuid required

Response

Successful Response

idstring uuid required
namestring required
key_prefixstring required
scopesstring required
rate_limit_per_minuteinteger required
rate_limit_per_dayinteger required
total_requestsinteger required
last_used_atstring date-time nullable required
is_activeboolean required
expires_atstring date-time nullable required
created_atstring date-time required
full_keystring required
rotated_from_idstring uuid required
new_idstring uuid required

Changes

No recorded changes to this operation across all 1 revision of this API.