Authorization

Using OAuth2 credentials you will be able to authorize your app with THX API.

Obtain your clientId and `clientSecret` in Developer -> API Keys of your campaign dashboard.

Create Authorization Header

  1. Combine the client ID and client secret with a colon (:) separator.

    • Example: clientId:clientSecret

  2. Encode the concatenated string using Base64 encoding.

    • Example: Y2xpZW50SWQ6Y2xpZW50U2VjcmV0

  3. Construct the Authorization header by prepending the word "Basic" followed by a space to the Base64-encoded string.

    • Example: Basic Y2xpZW50SWQ6Y2xpZW50U2VjcmV0

Request access token

Create an HTTP request using your authorization header and the parameters given below to obtain an access token for our authorization server.

Create access token

POST https://auth.thx.network/token

Headers

NameTypeDescription

Content-Type*

String

application/x-www-form-urlencoded

Authorization*

String

Basic Y2xpZW50SWQ6Y2xpZW50U2VjcmV0

Request Body

NameTypeDescription

grant_type

String

client_credentials

scope

String

openid events:write identities:read identities:write

{
    access_token: "eyJhbGciOiJSUzI1...",
    expires_in: 86400,
    id_token: "eyJhbGciOiJSUzI1...",
    scope: "openid events:write identities:read identities:write",
    token_type: "Bearer"
}

Last updated