Skip to main content
POST

Authorizations

Authorization
string
header
required

HTTP Basic with your client_id and client_secret, only on POST /v1/oauth/token for the client_credentials grant. You may send them as client_id and client_secret form fields instead.

Body

application/x-www-form-urlencoded

One endpoint, two grants. grant_type picks the shape.

grant_type
string
required
Allowed value: "client_credentials"
scope
string

Space-separated scopes. Omit to get every scope the client holds. Asking for one it does not hold fails with invalid_scope.

Example:

"enrollments:read enrollments:write logs:write"

tenant_id
string<uuid>

The brand this token is for. Required for a platform partner's client, which acts for several brands and gets one token per brand (tenant_required without it, tenant_not_permitted for a brand it may not act for). A brand's own client may omit it or send its own tenant id.

Example:

"a0000000-0000-4000-8000-000000000002"

client_id
string

Only when not using HTTP Basic.

Example:

"demo_brand_integration"

client_secret
string

Only when not using HTTP Basic.

Example:

"example-client-secret-not-real"

Response

Token issued.

access_token
string
required

Opaque to callers. Do not parse it.

Example:

"trx_at_example_not_a_real_token"

token_type
string
required
Allowed value: "Bearer"
expires_in
integer
required

Seconds. 3600 for client tokens, 900 for patient tokens.

Example:

3600

scope
string

Space-separated scopes granted. Absent on patient tokens.

Example:

"enrollments:read enrollments:write logs:write"

issued_token_type
string

Token exchange only (RFC 8693).

Allowed value: "urn:ietf:params:oauth:token-type:access_token"