Skip to main content
POST
Rotate a personal API key.

Authorizations

Authorization
string
header
required

Bearer JWT token or API Key (sk-*).

Path Parameters

key
string
required

Body

application/json
version
number
required

Current API key version.

Required range: x >= 0
gracePeriodMs
number
default:0

Old-key overlap in milliseconds. Zero revokes the old key immediately. Existing expiration is never extended.

Required range: 0 <= x <= 31536000000
expireAt
string<date-time> | null

New-key ISO expiration, at least four hours ahead. Omission inherits the current expiration; null creates a key without expiration.

code
string

Authenticator confirmation for personal accounts.

Required string length: 6

Response

201
Last modified on October 5, 2026