Authentication
The Advertiser API uses an API key and API secret to authenticate requests.
You can request your API key and secret from the TyrAds team. To authenticate a request, provide the both API key and API secret in the header of the request:
Header Name
Value
X-Api-Key
YOUR_API_KEY
X-Api-Secret
YOUR_API_SECRET
curl -H "X-Api-Key: YOUR_API_KEY" -H "X-Api-Secret: YOUR_API_SECRET" https://api.tyrads.comimport requests
# Create headers with the API key and secret
headers = {
'X-Api-Key': 'YOUR_API_KEY',
'X-Api-Secret': 'YOUR_API_SECRET', # You can add other headers as needed
}
# Set API URL
url = 'https://api.tyrads.com/'
# Make the API request with the headers
response = requests.get(url, headers=headers)Please be sure to keep your API key and secret secure! Do not share them in emails, chat messages, client-side code, or publicly accessible sites.
If you have accidentally shared an API key and secret publicly, please contact the TyrAds team to revoke it
Last updated