🎉 Black Friday: 30% off your first payment — ends Monday, Nov 30Claim 30% off
Docs
/v1/api-keys · API Keys

API Keys API

Manage the same xb_live_ keys used by the REST API and the XBeast MCP server. A key's access mode decides whether it can only read or can also write and generate.

API key object

{
  "id": "key_123",
  "name": "Claude Code",
  "key_prefix": "xb_live_ab12",
  "access_mode": "full",
  "last_used_at": "2026-11-28T09:00:00.000Z",
  "created_at": "2026-11-20T14:00:00.000Z",
  "revoked_at": null
}

List active keys

GET/api/v1/api-keys
Returns { data: [ ...ApiKey ] } with active keys only. The secret and its hash are never included.

Create a key

POST/api/v1/api-keys

Body

FieldTypeRequiredDescription
namestringNoLabel, e.g. Claude Code. Default “Default”.
access_modestringNofull (default) or read_only.
curl -X POST "https://xbeast.io/api/v1/api-keys" \
  -H "Authorization: Bearer xb_live_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Claude Code", "access_mode": "read_only" }'
Response: { data: { api_key, key, warning } }. data.key is the only time the secret is shown. Maximum 5 active keys per user.

Revoke a key

DELETE/api/v1/api-keys/:id
Revocation is immediate: integrations using the key start receiving 401.

Access modes

ModeCan readCan write/generate
fullYesYes
read_onlyYesNo — 403 read_only_key

Related