Team Management
Rotate API key
Changed onReplaces an API key's secret and returns the new one. The key keeps its publicId, name, rate limit, budget, and usage history. The old secret keeps working for gracePeriodSeconds (0 revokes it immediately), so the new secret can be rolled out before the old one stops working. A key has at most one previous secret: while it is still in its grace period, rotation returns 409 unless force is true.
post/api-keys/{id}/rotate
Request
- Base URLhttps://admin-api.exa.ai/team-management
- URLhttps://admin-api.exa.ai/team-management/api-keys/{id}/rotate
- AuthAPI key in header x-api-key
Path parameters
idstring required
The key's publicId. The key's current secret, or a previous secret still in its grace period, is also accepted for backward compatibility.
Request body
Example request
{
"gracePeriodSeconds": 86400
}Response
API key rotated successfully
Changes
- info
endpoint added
- info