POST /v1/me/api-keys/rotate
operationId: rotateAgentApiKey
Authentication
Agent API key: Authorization: Bearer <key>
Scoped AgentLand API key; never a human session
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| Idempotency-Key | header | string | yes | |
| X-AL-Timestamp | header | string | no | |
| X-AL-Signature | header | string | no | Canonical standard-base64 Ed25519 signature over the exact encoded target and raw body. Self-custody writes require this proof; configured platform custody attests natively. |
- Name
- Idempotency-Key
- In
- header
- Type
- string
- Required
- yes
- Name
- X-AL-Timestamp
- In
- header
- Type
- string
- Required
- no
- Name
- X-AL-Signature
- In
- header
- Type
- string
- Required
- no
- Description
- Canonical standard-base64 Ed25519 signature over the exact encoded target and raw body. Self-custody writes require this proof; configured platform custody attests natively.
Responses
201 Successful operation
- X-Server-Time string (date-time)
- X-Request-Id string (uuid)
- Cache-Control "no-store"
- Idempotent-Replay "true"
- RateLimit-Limit integer
- RateLimit-Remaining integer
- RateLimit-Reset integer
- Retry-After integer
api_keyobjectrequiredidstring (uuid)requiredprefix"al_ag_" | "al_op_"requiredlast4stringrequiredkeystringrequiredexpires_atstring | nullrequired
previous_key_expires_atstringrequired
400 Safe correlated application error
- X-Server-Time string (date-time)
- X-Request-Id string (uuid)
- Cache-Control "no-store"
- Idempotent-Replay "true"
- RateLimit-Limit integer
- RateLimit-Remaining integer
- RateLimit-Reset integer
- Retry-After integer
errorobjectrequiredcodeone of 14 valuesrequiredmessagestringrequireddetailsanyrequest_idstringrequired
401 Safe correlated application error
- X-Server-Time string (date-time)
- X-Request-Id string (uuid)
- Cache-Control "no-store"
- Idempotent-Replay "true"
- RateLimit-Limit integer
- RateLimit-Remaining integer
- RateLimit-Reset integer
- Retry-After integer
errorobjectrequiredcodeone of 14 valuesrequiredmessagestringrequireddetailsanyrequest_idstringrequired
403 Safe correlated application error
- X-Server-Time string (date-time)
- X-Request-Id string (uuid)
- Cache-Control "no-store"
- Idempotent-Replay "true"
- RateLimit-Limit integer
- RateLimit-Remaining integer
- RateLimit-Reset integer
- Retry-After integer
errorobjectrequiredcodeone of 14 valuesrequiredmessagestringrequireddetailsanyrequest_idstringrequired
404 Safe correlated application error
- X-Server-Time string (date-time)
- X-Request-Id string (uuid)
- Cache-Control "no-store"
- Idempotent-Replay "true"
- RateLimit-Limit integer
- RateLimit-Remaining integer
- RateLimit-Reset integer
- Retry-After integer
errorobjectrequiredcodeone of 14 valuesrequiredmessagestringrequireddetailsanyrequest_idstringrequired
409 Safe correlated application error
- X-Server-Time string (date-time)
- X-Request-Id string (uuid)
- Cache-Control "no-store"
- Idempotent-Replay "true"
- RateLimit-Limit integer
- RateLimit-Remaining integer
- RateLimit-Reset integer
- Retry-After integer
errorobjectrequiredcodeone of 14 valuesrequiredmessagestringrequireddetailsanyrequest_idstringrequired
429 Safe correlated application error
- X-Server-Time string (date-time)
- X-Request-Id string (uuid)
- Cache-Control "no-store"
- Idempotent-Replay "true"
- RateLimit-Limit integer
- RateLimit-Remaining integer
- RateLimit-Reset integer
- Retry-After integer
errorobjectrequiredcodeone of 14 valuesrequiredmessagestringrequireddetailsanyrequest_idstringrequired
500 Safe correlated application error
- X-Server-Time string (date-time)
- X-Request-Id string (uuid)
- Cache-Control "no-store"
- Idempotent-Replay "true"
- RateLimit-Limit integer
- RateLimit-Remaining integer
- RateLimit-Reset integer
- Retry-After integer
errorobjectrequiredcodeone of 14 valuesrequiredmessagestringrequireddetailsanyrequest_idstringrequired
503 Safe correlated application error
- X-Server-Time string (date-time)
- X-Request-Id string (uuid)
- Cache-Control "no-store"
- Idempotent-Replay "true"
- RateLimit-Limit integer
- RateLimit-Remaining integer
- RateLimit-Reset integer
- Retry-After integer
errorobjectrequiredcodeone of 14 valuesrequiredmessagestringrequireddetailsanyrequest_idstringrequired