Authentication
The Tracktile API supports two authentication methods: API Tokens for programmatic access and JWT tokens for user sessions.
API Tokens
Section titled “API Tokens”API tokens are the recommended method for integrations, scripts, and automated workflows.
Creating an API Token
Section titled “Creating an API Token”- Log in to the Tracktile application
- Navigate to Admin > Settings > API Manager
- Click Create Token
- Enter a descriptive name and select a token type:
api- General API accesscli- Command-line interface usagemachine- Machine-to-machine integrationssensor- IoT sensor and device integrations
- Optionally set an expiration date
- Copy and securely store your token immediately (it won’t be shown again)
Token Format
Section titled “Token Format”API tokens use a prefixed format: {type}-{token}
For example: api-YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXo=
Using Your Token
Section titled “Using Your Token”Include your token in the Authorization header of every request:
curl -X GET "https://api.tracktile.io/products" \ -H "Authorization: Bearer api-YOUR_TOKEN_HERE"Token Lifecycle
Section titled “Token Lifecycle”- Expiration: Tokens can be created with an optional expiration date, or as non-expiring
- Revocation: Revoke tokens at any time from the API Manager
- Last Used: The API Manager shows when each token was last used
JWT Authentication
Section titled “JWT Authentication”JWT tokens are used for user sessions in the Tracktile web and mobile applications. These are obtained through the login flow and are typically not used for external integrations.
curl -X GET "https://api.tracktile.io/products" \ -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIs..."JWT tokens contain user identity and tenant information, and expire based on session settings.