Mint an API key
Mints a new API key and returns the full `al_live_*` bearer token EXACTLY ONCE in the response — it is never retrievable again, so store it immediately. Requires a write-scoped key (owner write access).
Authorization
bearerAuth Your al_live_<prefix>_<secret> API key. Mint and manage keys in the dashboard.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/admin/api-keys" \ -H "Content-Type: application/json" \ -d '{ "name": "Zapier production integration", "scopes": [ "read", "write" ] }'{ "id": 42, "name": "Zapier production integration", "prefix": "a1b2c3d4", "token": "al_live_a1b2c3d4_S3cr3tPortionShownOnceCopyItNow", "scopes": [ "read", "write" ], "created_at": 1751328000}{ "detail": { "code": "invalid_scope", "message": "Invalid scope values: ['admin']. Allowed: ['read', 'write']" }}{ "detail": "auth required"}{ "detail": { "code": "scope_escalation", "message": "Key with scopes ['read'] cannot mint scopes ['write']" }}List API keys
Lists all API keys for the authenticated owner with their metadata. The secret token is never included — only the public prefix and metadata are returned. Requires a read-scoped key.
Revoke an API key
Soft-revokes the API key with the given id. After revocation any request presenting this key is rejected. Requires a write-scoped key.