Sign in

Welcome to our Support Center

Get help with integration and live campaigns

Welcome to our Support Center. Get help with integration and live campaigns

Testing Criteo Marketing API

 

The below elements will help you test our Criteo REST API from the command line or from a browser, using Curl to simulate the different GET and POST calls that will enable you to retrieve your first reports.

Highlighted in orange are the elements you will need to change in your calls.

Curl for authentication 

curl -X POST 
--header 'Content-Type: application/x-www-form-urlencoded' 
--header 'Accept: application/json' 
-d 'client_id=[clientId]&client_secret=[clientSecret]&grant_type=client_credentials' 
'https://api.criteo.com/marketing/oauth2/token'

API response: Token

Curl for portfolio

curl -X GET 
--header 'Accept: application/json' 
--header 'Authorization: Bearer [token]' 
'https://api.criteo.com/marketing/v1/portfolio'

API response: AdvertiserId

Curl to get a list of all the audiences corresponding with their corresponding files

curl -X POST 
--header 'Content-Type: application/json'
--header 'Accept: application/octet-stream'
--header 'Authorization: Bearer [token]
-d '{
 "client_id": "[client_id]"
 }'
'https://api.criteo.com/marketing/v1/clients/{client_id}/audiences'

API response: all the lists retrieved

Swagger

Swagger is the world's largest framework of API developer tools for test and deployment. You can also use our Swagger tools to manually test the API.

The Criteo Swagger is available at this url: https://api.criteo.com/marketing/swagger/

Note: This Swagger links to the live Criteo Management Center interface. Please note that any test performed in this environment will impact your live campaigns.

Was this article helpful?
0 out of 0 found this helpful
Powered by Zendesk