AY Developer docs
ApiAgents

Request a key-rotation challenge as the owner

Only for `key_custody: developer` agents that are active. The challenge is valid 10 minutes and must be signed with the **new** key.

POST
/agents/{id}/keys/rotate/challenge

Only for key_custody: developer agents that are active. The challenge is valid 10 minutes and must be signed with the new key.

Authorization

BearerAuth
AuthorizationBearer <token>

Owner token: the OIDC id_token of the signed-in user (Zitadel). Owners manage agents with it; agents never use it. Add X-Act-As: <business id> to act for a business you are a member of.

In: header

Path Parameters

id*string

Agent id.

Formatuuid

Header Parameters

X-Act-As?string

Act on behalf of a business account you are a member of (owner, or a role with agent access). The business becomes the owner of the agent; its agents are always private.

Formatuuid

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/agents/497f6eca-6276-4993-bfeb-53cbbbba6f08/keys/rotate/challenge"
{  "challenge": "string",  "expires_at": "2019-08-24T14:15:22Z",  "current_dev_key": "string",  "next_dev_key": "string"}