Skip to main content
POST
Create new Token

Body

application/json
name
string
required

The token name

Required string length: 1 - 200
token_type
enum<string>
  • sandbox_api_token - Sandbox
  • api_token - Back
Available options:
sandbox_api_token,
api_token
balance
string<decimal> | null

Optional remaining credits balance for this Token, if active_balance is set to True and the balance reaches 0, this token will become unusable

Pattern: ^-?\d{0,5}(?:\.\d{0,9})?$
expire_time
string<date-time> | null
active_balance
boolean

Weither to use the balance field or not.

balance_reset_amount
string<decimal> | null

The amount this token's balance is reset to at the start of each balance_reset_period. Null when balance_reset_period is 'none'.

Pattern: ^-?\d{0,5}(?:\.\d{0,9})?$
balance_reset_period
enum<string>

How often this token's balance is reinitialized to balance_reset_amount. 'none' = one-time balance (default, current behaviour).

  • none - None
  • daily - Daily
  • weekly - Weekly
  • monthly - Monthly
Available options:
none,
daily,
weekly,
monthly

Response

201 - application/json
name
string
required

The token name

Maximum string length: 200
token_type
enum<string>
  • sandbox_api_token - Sandbox
  • api_token - Back
Available options:
sandbox_api_token,
api_token
balance
string<decimal> | null

Optional remaining credits balance for this Token, if active_balance is set to True and the balance reaches 0, this token will become unusable

Pattern: ^-?\d{0,5}(?:\.\d{0,9})?$
expire_time
string<date-time> | null
active_balance
boolean

Weither to use the balance field or not.

balance_reset_amount
string<decimal> | null

The amount this token's balance is reset to at the start of each balance_reset_period. Null when balance_reset_period is 'none'.

Pattern: ^-?\d{0,5}(?:\.\d{0,9})?$
balance_reset_period
enum<string>

How often this token's balance is reinitialized to balance_reset_amount. 'none' = one-time balance (default, current behaviour).

  • none - None
  • daily - Daily
  • weekly - Weekly
  • monthly - Monthly
Available options:
none,
daily,
weekly,
monthly