Skip to Content
Docs

Rotate an agent's API key

POST
/api/regenerate_agent_key/{agent_id}

Rotate an agent's API key. The previous key is invalidated immediately and a fresh key is returned once. Historical logging and usage records are re-pointed to the new key so analytics stay intact. Owner only.

Personal access token scope: agents:keys.

Authorization

bearer
headerAuthorizationBearer <token>

A session token or a personal access token. Leave it empty when the instance runs without authentication (AUTH_TYPE unset).

Path Parameters

agent_id*string

ID of the agent

Response Body

Success

Example Request
curl -X POST 'http://localhost:7091/api/regenerate_agent_key/string'
Example Response200
Empty