Create an agent token
Use this to create additional API keys for an existing agent (e.g., for zero-downtime key rotation). The initial key is created automatically by CreateAgent.
Scope: agent:write
Authorization
bearerAuth Personal Access Token (PAT) or Service Access Token (SAT). Pass the token in the Authorization header: Bearer admp_...
In: header
Path Parameters
The agent to bind this key to (UUID).
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
CreateApiKeyRequest contains the parameters for creating a new API key bound to an agent.
Response Body
application/json
curl -X POST "https://example.com/v1/agents/497f6eca-6276-4993-bfeb-53cbbbba6f08/tokens" \ -H "Content-Type: application/json" \ -d '{ "name": "string" }'{ "api_key": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "tenant_id": "34f5c98e-f430-457b-a812-92637d0c6fd0", "name": "string", "key_prefix": "string", "scopes": [ "string" ], "status": "API_KEY_STATUS_UNSPECIFIED", "binding_type": "BINDING_TYPE_UNSPECIFIED", "binding_id": "string", "expires_at": "2023-01-15T01:30:15.01Z", "last_used_at": "2023-01-15T01:30:15.01Z", "revoked_at": "2023-01-15T01:30:15.01Z", "created_by": { "id": "string", "display_name": "string", "email": "string" }, "created_at": "2023-01-15T01:30:15.01Z" }, "plain_text_key": "string"}Create an agent POST
The request's `kind` selects the agent's execution plane (TERRAFORM or KUBERNETES) and determines the key's auto-assigned scopes. The kind is immutable. The response includes a `plain_text_key`: the raw API key secret shown exactly once. Deploy this key to the agent binary for authentication. Scope: `agent:write`
Delete an agent DELETE
Scope: `agent:write`