Tokens API
Create a token
Response
201:
List tokens
200:
Revoke a token
200:
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Create, list, and revoke API tokens.
POST /api/v1/tokens
{
"name": "CI Pipeline",
"scopes": ["write:secrets"],
"ttlDays": 90
}
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Human-readable name (max 100 chars) |
scopes | string[] | Yes | read:secrets, write:secrets, or admin |
ttlDays | number | null | No | Days until expiry. null = no expiry |
201:
{
"success": true,
"data": {
"id": "64b1f2...",
"name": "CI Pipeline",
"rawToken": "env_live_...",
"displayPrefix": "env_live_ae3",
"scopes": ["write:secrets"],
"expiresAt": "2026-11-18T00:00:00.000Z"
}
}
GET /api/v1/tokens
200:
{
"success": true,
"data": [
{
"id": "64b1f2...",
"name": "CI Pipeline",
"displayPrefix": "env_live_ae3",
"scopes": ["write:secrets"],
"createdAt": "2026-08-18T10:00:00.000Z",
"expiresAt": "2026-11-18T00:00:00.000Z",
"lastUsedAt": "2026-08-20T09:00:00.000Z"
}
]
}
DELETE /api/v1/tokens/:id
200:
{ "success": true }