Skip to main content

Application Access Tokens with Client Credentials Flow

The Client Credentials Flow is used in server-to-server authentication.

Request Authorization

To generate an Application Access Token, send a POST request to the /oauth/token endpoint of the Tiltify OAuth 2.0 Service with the following parameters encoded in application/json:

{
"grant_type": "client_credentials",
"client_id": "<client_id>",
"client_secret": "<client_secret>",
"scope": "<scopes>"
}

Example

curl -X POST https://v5api.tiltify.com/oauth/token \
-H 'Content-Type: application/json' \
-d '{"client_id":"e98e79be37f830026564ed5c190e01200c3f8f1707c4af36993c974e461dc64d","client_secret":"9e255194d71ab8594e665af33eb207e91cf122a00573b92d0f1965e0e4588f45", "grant_type": "client_credentials", "scope": "public"}'

If everything goes well, you should receive a successful response that looks like:

{
"access_token": "a63ba108db415df11328c5f48922d9bd27ff56f1a6c13274f577b2ad7ebc7491",
"created_at": "2023-04-17T15:22:28Z",
"expires_in": 7200,
"refresh_token": null,
"scope": "public",
"token_type": "bearer"
}

You can now use your Application Access Token to make requests to the Tiltify API.

Refreshing Application Access Tokens

For security reasons, we do not provide infinite expiry Access Tokens. You will have to generate new Access Tokens when the provided ones expire.

You can follow the guide above to make another request to the /oauth/token endpoint and generate a new Application Access Token.