Regenerate API key
Rotates an API key: the old key is revoked immediately and a new key with the same name, description, M2M client, and original expiry is returned with HTTP 200. The new apiToken is shown only once. A bearer caller may rotate only its own authenticated M2M client’s key (403 PERMISSION_DENIED for another client, before revoking the old key). The bearer must also hold every scope of the key’s M2M client (403 PERMISSION_DENIED with details.exceedingScopes otherwise). An inactive M2M client returns 400. The organization’s API key plan limit applies (403).
Requires every scope: api-keys:write.
Authentication
AuthorizationBearer
JWT returned by POST /api/auth/token-exchange. Amazon, authorization invitations, and developer credentials require API-key-derived tokens.
Path parameters
id
Numeric API key ID.
Response
Success. apiToken is returned only in this response.
apiKey
oldKeyId
ID of the revoked key.
Errors
400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
500
Internal Server Error
503
Service Unavailable Error