Actian Corporation Access Tokens API
Create, list, rotate, and delete access tokens.
Create, list, rotate, and delete access tokens.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/actian:actian-access-tokens-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Actian VectorAI DB - Authentication Access Tokens API
description: Access token and admin user management for VectorAI DB.
version: 1.0.0
contact:
name: Actian Corporation
url: https://www.actian.com
servers:
- url: http://localhost:6573
description: Local development server (REST API)
- url: https://api.vectorai.actian.com
description: Production server
security:
- bearerAuth: []
tags:
- name: Access Tokens
description: Create, list, rotate, and delete access tokens.
paths:
/auth/api_key:
post:
tags:
- Access Tokens
summary: Create access token
description: 'Creates a new API key with the specified name, description, expiration, and permissions.
**Prerequisite:** Authentication must be enabled before calling this endpoint. Call `PATCH /auth/enabled` with `{"enabled": true}` using an admin JWT first. If `auth_enabled` is `false`, the server rejects this request with `403 Forbidden` and the message `"API key management API requires auth_enabled=true"`.
## Permission model
Access token permissions use a bitmask model.
| Name | Value | Meaning |
| --- | --- | --- |
| `read` | 1 | Read access |
| `write` | 2 | Write access |
| `admin` | 4 | Admin access |
`admin` is an independent permission bit. It does not automatically grant `read` or `write`.
Common combinations:
| Bitmask | Permission string | Meaning |
| --- | --- | --- |
| 1 | `read` | Read only |
| 2 | `write` | Write only |
| 4 | `admin` | Admin only |
| 5 | `read,admin` | Read and admin |
| 6 | `write,admin` | Write and admin |
| 7 | `read,write,admin` | Read, write, and admin |
The create-token API accepts the canonical comma-separated permission names, and the server stores them as the corresponding bitmask.
When using an admin JWT, the server uses the persisted JWT secret from `server_params.btr`. If `ACTIAN_VECTORAI_JWT_SECRET` is set at startup, that value overrides the persisted secret and is saved for subsequent restarts.'
operationId: create_access_token
parameters:
- name: Authorization
in: header
required: true
schema:
type: string
description: Admin JWT or admin access token. Format `Bearer <admin-jwt-or-access-token>`.
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- name
- permission
properties:
name:
type: string
description: Human-readable name for the token.
description:
type: string
description: Optional description of the token's intended use.
will_expire:
type: boolean
description: Whether the token expires. When `false`, the token is valid indefinitely.
default: false
expires_in_seconds:
type: integer
description: Number of seconds until the token expires. Only applies when `will_expire` is `true`.
permission:
type: string
description: Comma-separated permission names. Valid values are `read`, `write`, `admin`, or any combination.
example: read,admin
responses:
'200':
description: Token created successfully.
content:
application/json:
schema:
type: object
properties:
id:
type: integer
description: Unique identifier for the access token.
name:
type: string
description: Human-readable name for the token.
description:
type: string
description: Description of the token's intended use.
api_key:
type: string
description: The raw API key value. Store this securely, as it cannot be retrieved after creation.
created_at:
type: string
format: date-time
description: Timestamp when the token was created, in RFC 3339 UTC format.
expired_at:
type:
- string
- 'null'
format: date-time
description: Timestamp when the token expires, in RFC 3339 UTC format. `null` when `will_expire` is `false`.
will_expire:
type: boolean
description: Whether the token has an expiration date.
permission:
type: string
description: Comma-separated permission names assigned to the token.
examples:
success:
value:
id: 12
name: reader-admin-token
description: Used by the analytics dashboard to run read-only admin checks.
api_key: vdai_<newly-generated-token>
created_at: '2026-04-02T08:30:00Z'
expired_at: '2026-04-03T08:30:00Z'
will_expire: true
permission: read,admin
'403':
description: Authentication is not enabled on the server.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
examples:
auth_disabled:
value:
status: error
message: API key management API requires auth_enabled=true
x-codeSamples:
- lang: cURL
label: Create access token
source: "curl -X POST http://localhost:6573/auth/api_key \\\n -H \"Content-Type: application/json\" \\\n -H 'Authorization: Bearer <admin-jwt-or-access-token>' \\\n -d '{\n \"name\": \"reader-admin-token\",\n \"description\": \"Used by the analytics dashboard to run read-only admin checks.\",\n \"will_expire\": true,\n \"expires_in_seconds\": 86400,\n \"permission\": \"read,admin\"\n }'\n"
/auth/api_keys:
get:
tags:
- Access Tokens
summary: List access tokens
description: 'Returns a list of all access tokens. The response does not include the raw token values.
Requires `auth_enabled=true` and an admin access token or admin JWT.
Timestamps are returned as RFC 3339 UTC strings. When `will_expire` is `false`, `expired_at` is `null`.'
operationId: list_access_tokens
parameters:
- name: Authorization
in: header
required: true
schema:
type: string
description: Admin JWT or admin access token. Format `Bearer <admin-jwt-or-access-token>`.
responses:
'200':
description: List of access tokens.
content:
application/json:
schema:
type: array
items:
type: object
properties:
id:
type: integer
description: Unique identifier for the access token.
name:
type: string
description: Human-readable name for the token.
description:
type: string
description: Description of the token's intended use.
created_at:
type: string
format: date-time
description: Timestamp when the token was created, in RFC 3339 UTC format.
expired_at:
type:
- string
- 'null'
format: date-time
description: Timestamp when the token expires. `null` when `will_expire` is `false`.
will_expire:
type: boolean
description: Whether the token has an expiration date.
permission:
type: string
description: Comma-separated permission names assigned to the token.
examples:
success:
value:
- id: 12
name: reader-admin-token
description: Used by the analytics dashboard to run read-only admin checks.
created_at: '2026-04-02T08:30:00Z'
expired_at: '2026-04-03T08:30:00Z'
will_expire: true
permission: read,admin
- id: 13
name: writer-token
description: Used by the nightly import job.
created_at: '2026-04-02T09:00:00Z'
expired_at: null
will_expire: false
permission: write
'403':
description: Authentication is not enabled on the server.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
x-codeSamples:
- lang: cURL
label: List access tokens
source: "curl -X GET http://localhost:6573/auth/api_keys \\\n -H \"Accept: application/json\" \\\n -H 'Authorization: Bearer <admin-jwt-or-access-token>'\n"
/auth/api_key/{token_id}:
delete:
tags:
- Access Tokens
summary: Delete access token
description: 'Deletes an access token by its ID. The token is immediately invalidated and can no longer be used for authentication.
Requires `auth_enabled=true` and an admin access token or admin JWT.'
operationId: delete_access_token
parameters:
- name: token_id
in: path
required: true
schema:
type: integer
description: The unique identifier of the access token to delete.
- name: Authorization
in: header
required: true
schema:
type: string
description: Admin JWT or admin access token. Format `Bearer <admin-jwt-or-access-token>`.
responses:
'200':
description: Token deleted successfully.
content:
application/json:
schema:
$ref: '#/components/schemas/StatusResponse'
examples:
success:
value:
status: success
message: Access token deleted successfully
'404':
description: Token not found.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
examples:
not_found:
value:
status: error
message: Access token not found
'401':
description: Missing or invalid authorization credentials.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
examples:
unauthorized:
value:
status: error
message: Invalid or missing authorization token
'403':
description: Authentication is not enabled on the server.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
examples:
auth_disabled:
value:
status: error
message: API key management API requires auth_enabled=true
x-codeSamples:
- lang: cURL
label: Delete access token
source: "curl -X DELETE http://localhost:6573/auth/api_key/12 \\\n -H \"Accept: application/json\" \\\n -H 'Authorization: Bearer <admin-jwt-or-access-token>'\n"
/auth/api_key/{token_id}/rotate:
post:
tags:
- Access Tokens
summary: Rotate access token
description: 'Generates a new raw token for an existing access token and invalidates the previous raw token immediately. The token `id`, `name`, `description`, `permission`, `will_expire`, and `expired_at` values are preserved.
Requires `auth_enabled=true` and an admin access token or admin JWT. Expired tokens cannot be rotated.'
operationId: rotate_access_token
parameters:
- name: token_id
in: path
required: true
schema:
type: integer
description: The unique identifier of the access token to rotate.
- name: Authorization
in: header
required: true
schema:
type: string
description: Admin JWT or admin access token. Format `Bearer <admin-jwt-or-access-token>`.
responses:
'200':
description: Token rotated successfully. Returns the new raw token.
content:
application/json:
schema:
type: object
properties:
id:
type: integer
description: Unique identifier for the access token.
name:
type: string
description: Human-readable name for the token.
description:
type: string
description: Description of the token's intended use.
api_key:
type: string
description: The new raw API key value. Store this securely, as it cannot be retrieved after rotation.
created_at:
type: string
format: date-time
description: Original creation timestamp, in RFC 3339 UTC format.
expired_at:
type:
- string
- 'null'
format: date-time
description: Expiration timestamp. `null` when `will_expire` is `false`.
will_expire:
type: boolean
description: Whether the token has an expiration date.
permission:
type: string
description: Comma-separated permission names assigned to the token.
examples:
success:
value:
id: 12
name: reader-admin-token
description: Used by the analytics dashboard to run read-only admin checks.
api_key: vdai_<newly-generated-token>
created_at: '2026-04-02T08:30:00Z'
expired_at: '2026-04-03T08:30:00Z'
will_expire: true
permission: read,admin
'400':
description: Token is expired and cannot be rotated.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
examples:
expired:
value:
status: error
message: Cannot rotate an expired access token
'403':
description: Authentication is not enabled on the server.
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
x-codeSamples:
- lang: cURL
label: Rotate access token
source: "curl -X POST http://localhost:6573/auth/api_key/12/rotate \\\n -H \"Accept: application/json\" \\\n -H 'Authorization: Bearer <admin-jwt-or-access-token>'\n"
components:
schemas:
StatusResponse:
type: object
properties:
status:
type: string
description: Operation result status.
message:
type: string
description: Human-readable status message.
ErrorResponse:
type: object
properties:
status:
type: string
description: Error status indicator.
message:
type: string
description: Human-readable error description.
securitySchemes:
bearerAuth:
type: http
scheme: bearer
bearerFormat: JWT
description: Admin JWT obtained from the login endpoint.