Management
Create an API key
Creates a key and returns the full secret exactly once.
Authorization
BearerAuth AuthorizationBearer <token>
Clerk session token (dashboard/management routes). In local dev mode use the X-Dev-User header instead.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
curl -X POST "https://example.com/manage/keys" \ -H "Content-Type: application/json" \ -d '{ "name": "Production" }'{ "id": "key_9f2c4b1a", "name": "Production", "prefix": "ext_live_a1b", "createdAt": "2019-08-24T14:15:22Z", "lastUsedAt": "2019-08-24T14:15:22Z", "revoked": true, "secret": "ext_live_a1b2c3d4e5f60718293a4b5c6d7e8f9012345678"}{ "error": { "code": "invalid_api_key", "message": "The provided API key is invalid or has been revoked." }}{ "error": { "code": "invalid_api_key", "message": "The provided API key is invalid or has been revoked." }}