Skip to main content
Skip table of contents

Authentication

In order to work with the API you will need an access token. You can obtain an access token by creating a client secret and client id through the API tokens UI in Tracket.

You can find the API tokens by navigating to Preferences in the top right corner of Tracket and then selecting the dropdown item API tokens.

image-20250618-121711.png

API tokens menu

After creating a new API token you will be presented with 2 fields: client secret, client id. You will need both to fetch an access token with the following command:

BASH
curl -X POST https://tracket.dev/api/2.0/oauth2/token \
  -H "Content-Type: application/json" \
  --data '{
    "grant_type": "client_credentials",
    "client_id": "YOUR_CLIENT_ID",
    "client_secret": "YOUR_CLIENT_SECRET"
  }'

This will return a json object with an access_token.

Short-lived token

This token is valid for 1 hour and you will need to fetch a new bearer token with your client secret, client id and account id to get a new one. {% endhint %}

You can now query our API with the authorization header Bearer YOUR_ACCESS_TOKEN.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.