Learn how to authenticate your API requests with Sales Track.
All API requests require authentication using API keys. You'll need both an API Key and Secret Key to access our endpoints.
Include the following headers in every API request:
X-API-Key: your_api_key_here
X-Secret-Key: your_secret_key_here
Content-Type: application/json
const apiKey = 'your_api_key_here'; const secretKey = 'your_secret_key_here'; const response = await fetch('/api/integrations/crm/merchandisers', { method: 'GET', headers: { 'X-API-Key': apiKey, 'X-Secret-Key': secretKey, 'Content-Type': 'application/json' } }); const data = await response.json();
<?php $apiKey = 'your_api_key_here'; $secretKey = 'your_secret_key_here'; $curl = curl_init(); curl_setopt_array($curl, [ CURLOPT_URL => '/api/integrations/crm/merchandisers', CURLOPT_RETURNTRANSFER => true, CURLOPT_HTTPHEADER => [ 'X-API-Key: ' . $apiKey, 'X-Secret-Key: ' . $secretKey, 'Content-Type: application/json' ] ]); $response = curl_exec($curl); $data = json_decode($response, true); curl_close($curl); ?>
import requests api_key = 'your_api_key_here' secret_key = 'your_secret_key_here' headers = { 'X-API-Key': api_key, 'X-Secret-Key': secret_key, 'Content-Type': 'application/json' } response = requests.get('/api/integrations/crm/merchandisers', headers=headers) data = response.json()
When authentication fails, you'll receive one of these error responses:
// Missing API Key or Secret Key { "error": "API key and secret key are required" } // Invalid credentials { "error": "Invalid API credentials" } // Expired or disabled key { "error": "API key has been disabled" }
Ready to start integrating? Contact our support team to get your API credentials.
Get your API keys to start making requests