Skip to main content
POST
create a static API token for your org

Authorizations

Authorization
string
header
required

Type "Bearer" followed by a space and token.

Body

application/json

Input

name
string
required

human-friendly name to identify the token later

duration
string
default:8760h

defaults to one year

role
string

org role granted to the token. must be assignable to API tokens; see GET /v1/roles?context=api_token. defaults to org_read_only. must be empty for personal tokens.

token_identity
string

"service_account" (default) creates a dedicated service account with the given role; "personal" issues the token against your own account and its existing roles, across all your orgs.

Response

201 - application/json

Created

api_token
string
id
string