Skip to main content
POST
Create API key

Authorizations

api-token
string
header
required

API key. Create and manage keys at /v4/account/api-keys or in the dashboard.

Body

application/json
name
string
required

Human-readable label for the key.

Maximum string length: 100
permissions
string[]
required

List of permission strings. Use GET /v4/account/api-keys/allowed-permissions to see what your account can grant.

Minimum array length: 1
allowed_subaccounts
string[]

Subaccount UUIDs this key can act on. Empty array means all subaccounts.

allowed_ips
string[]

IP addresses or CIDR ranges allowed to use this key. Empty array means no IP restriction.

expires_at
integer | null

Unix timestamp for key expiry. Must be in the future. Omit or null for no expiry.

Response

Created API key. The data.token field contains the 64-character secret — store it securely, it is only shown once.

success
boolean
message
string
Example:

"API key created successfully"

data
object
warning
string
Example:

"This token will only be shown once. Please copy it now."