Skip to Content
ApiAccess tokens

Create an Access token

Create a scoped Access token Admins and Owners, in a session (tokens cannot make tokens). 90 days unless `expires_in_days` (1–365) or `never_expires` says otherwise. The secret is returned once.

POST
/accounts/{account_id}/access-tokens

Create a scoped Access token

Admins and Owners, in a session (tokens cannot make tokens). 90 days unless expires_in_days (1–365) or never_expires says otherwise. The secret is returned once.

Authorization

headerAuthorizationBearer <token>

qlt_… Access token (kind api)

Path Parameters

account_id*string

Request Body

application/json
  1. body
name*string
Lengthlength <= 60
scopes*array<|>
Items1 <= items
expires_in_days?integer
Range1 <= value <= 365
never_expires?boolean

Response Body

Created

application/json
  1. response
id?string
name?string
scopes?array<string>
last_used_at?|
Formatdate-time
expires_at?|
Formatdate-time
created_at?string
Formatdate-time
secret?string

qlt_…, shown once

Example Request
curl -X POST 'https://tiltas.openpanel.sh/api/v1/accounts/string/access-tokens' \  -H 'Content-Type: application/json' \  -d '{  "name": "string",  "scopes": [    "read"  ]}'
Example Response
{  "id": "string",  "name": "string",  "scopes": [    "string"  ],  "last_used_at": "2019-08-24T14:15:22Z",  "expires_at": "2019-08-24T14:15:22Z",  "created_at": "2019-08-24T14:15:22Z",  "secret": "string"}