API Tokens
Create API token
Deprecated: This endpoint will be removed on 2026-07-17. Use POST /v2/clients/{clientId}/tokens instead.
Create an API token in the current account.
post/iam/clients/{clientId}/tokens
Path parameters
clientIdinteger required
Account ID.
Request body
Example request
{
"name": "My token",
"description": "It's my token",
"exp_date": "2021-01-01T12:00:00.000000Z",
"client_user": {
"role": {
"id": 1,
"name": "Administrators"
}
}
}Response
OK.
Example response
{
"name": "My token",
"description": "It's my token",
"exp_date": "2021-01-01T12:00:00.000000Z",
"client_user": {
"role": {
"id": 1,
"name": "Administrators"
},
"user_id": 123,
"user_name": "John Doe",
"user_email": "some@email.com",
"client_id": 456
},
"id": 42,
"created": "2021-01-01T12:00:00.000000Z",
"last_usage": "2021-01-01T12:00:00.000000Z"
}