Skip to main content
POST
JavaScript

Authorizations

Authorization
string
header
required

API Key or JWT User Token. If using an API Key, set the X-As-User header to act as a specific user. A JWT User Token is always scoped to a specific user.

Body

application/json
user_id
string
required
origin
string | null

Origin of the request, used for CSRF protection. If set, the token will only be valid for requests originating from this origin.

expires_in
string | null

Token lifetime, e.g., '30m', '2h', '1d'. Defaults to 24 hours if not provided. Maximum 30 days.

Example:

"30m"

Response

Successful Response

token
string
required
expires_at
string<date-time>
required