GuidesAPI ReferenceChangelogDiscussions
GuidesAPI ReferenceChangelogLog In

Retailers

📝

A FEW THINGS TO KNOW

1 - A retailer carries a selection of products from multiple brands
2 - Retailers represent publishers that hold advertising inventory for brands to advertise on
3 - An account may have access to one or more retailers, typically managed by Criteo

 

Endpoint

VerbEndpointDescription
GET /accounts/{accountId}/retailersGet All Retailers

 

Retailer Attributes

id

    Data Type: string

    Values: int64

    Description: Retailer ID

name

    Data Type: string

    Values: 100 char limit

    Description: Retailer name


 

Get All Retailers

This endpoint lists all retailers that carry the brands associated with an account. Response results will be provided in paginated form

https://api.criteo.com/2022-10/retail-media/accounts/{accountId}/retailers

Sample Request

curl -X GET "https://api.criteo.com/2022-10/retail-media/accounts/18446744073709551616/retailers" \
    -H "Authorization: Bearer <MY_ACCESS_TOKEN>"
import requests

url = "https://api.criteo.com/2022-07/retail-media/accounts/4/retailers"

payload={}
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer <MY_ACCESS_TOKEN>'
}

response = requests.request("GET", url, headers=headers, data=payload)

print(response.text)
OkHttpClient client = new OkHttpClient().newBuilder()
  .build();

MediaType mediaType = MediaType.parse("text/plain");

RequestBody body = RequestBody.create(mediaType, "");

Request request = new Request.Builder()
  .url("https://api.criteo.com/2022-07/retail-media/accounts/4/retailers")
  .method("GET", body)
  .addHeader("Accept", "application/json")
  .addHeader("Authorization", "Bearer <MY_ACCESS_TOKEN>")
  .build();

Response response = client.newCall(request).execute();
<?php
require_once 'HTTP/Request2.php';
$request = new HTTP_Request2();
$request->setUrl('https://api.criteo.com/2022-07/retail-media/accounts/4/retailers');
$request->setMethod(HTTP_Request2::METHOD_GET);
$request->setConfig(array(
  'follow_redirects' => TRUE
));

$request->setHeader(array(
  'Accept' => 'application/json',
  'Authorization' => 'Bearer <MY_ACCES_TOKEN>'
));

try {
  $response = $request->send();
  if ($response->getStatus() == 200) {
    echo $response->getBody();
  }
  
  else {
    echo 'Unexpected HTTP status: ' . $response->getStatus() . ' ' .
    $response->getReasonPhrase();
  }
}

catch(HTTP_Request2_Exception $e) {
  echo 'Error: ' . $e->getMessage();
}

Sample Request

{
    "data": [
        {
            "type": "RetailMediaRetailer",
            "id": "3239117063738827231",
            "attributes": {
                "name": "Retailer 123"
            }
        },
 
        // ...
 
        {
            "type": "RetailMediaRetailer",
            "id": "18159942378514859684",
            "attributes": {
                "name": "Retailer 789"
            }
        }
    ],
    "metadata": {
        "totalItemsAcrossAllPages": 10,
        "currentPageSize": 25,
        "currentPageIndex": 0,
        "totalPages": 1,
        "nextPage": null,
        "previousPage": null
    }
}

Responses

ResponseDescriptoin
:large-blue-circle: 200Call executed with success
:red-circle: 403API user does not have the authorization to make requests to the account ID. For an authorization request, follow the authorization request steps

What’s Next