Oore CI
ReferenceAPIOperationsAPI Tokens

Create API token

Creates a new API token. The plaintext token is returned only in this response and cannot be retrieved again.

Operation IDcreate_api_token
POST
/v1/api-tokens

Creates a new API token. The plaintext token is returned only in this response and cannot be retrieved again.

Authorization

bearer_auth
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/api-tokens" \  -H "Content-Type: application/json" \  -d '{    "name": "string",    "role": "string"  }'
{  "created_at": 0,  "expires_at": 0,  "id": "string",  "name": "string",  "prefix": "string",  "role": "string",  "token": "string"}