GuidesAPI ReferenceChangelog
GuidesAPI ReferenceChangelogLog In
Guides

Getting statistics

The statistical endpoints allows you to review the performance of your campaigns and pass on seller specific statistics to your sellers.

Metrics

The metrics reported by the endpoints are:

Metric GroupDescription
AimpressionsNumber of times product is shown in a banner
BclicksNumber of clicks on product
CcostAmount spent for clicks on products
DsaleUnitsNumber of products sold attributed to clicks
ErevenueRevenue generated by sales
FCR = Conversion RatesalesUnits / clicks
GCPO = Cost Per Ordercost / salesUnits
HCOS = Cost of Salecost / revenue
IROAS = Return On Add Spendrevenue / cost

 
The last six metrics can be computed in two ways depending on the policy to count only the sales that result from clicks on the same sellers product in a banner (same-seller) or not (any-seller). Reporting can be controlled by clickAttributionPolicy.

Aggregation Interval Size

The duration of the aggregation interval for the fundamental events is controlled by the filter parameter intervalSize. (Consider also the name frequency.) The valid values for this parameter are:

Query ParameterOptionsMeaning
intervalSizeYearAggregate all events that occur in the same year
MonthAggregate all events that occur in the same month
DayAggregate all events that occur in the same day (default)
HourAggregate all events that occur in the same hour

 
For example, the following request fetches aggregated seller statistics for the current day with a granularity of one row per hour. Every seller managed by this advertiser will have up to 24 rows in the response.

https://api.criteo.com/legacy/offsite-ads/stats/sellers?intervalSize=hour

 

📘

The default interval size is day. If the interval size is hour, then the maximum date range allowed is one month.

 

Date Filtering

Filtering the results to events that happened in a temporal interval is done by setting the date filter parameters. These are startDate and the endDate. The start date includes all events timestamped since the beginning of that day while the end date includes events until the end of day.

Query ParameterFormatMeaning
startDateYYYY-MM-DDFilter out all events that occur before date (default is the value of endDate)
endDateYYYY-MM-DDFilter out all events that occur after date (default is today’s date)

 
If the end date is left of it defaults to today. If the start date is left off it defaults to the end date. As a result, the default query returns one day of stats. Using just the end date returns a single day as well:

https://api.criteo.com/legacy/offsite-ads/stats/sellers?endDate=2019-01-01

 

📘

There are a few constraints. The start date must not be in the future and must be on or precede the end date. The format to use for each is YYY-MM-DD (e.g. 2018-04-30). The maximum duration of the date range is 1 year. If the granularity is hour, then the maximum duration of the date range is 1 month. Note that month and year aggregate values may contain partial data if filtered by date.

 

Count Filtering

Filtering the results to a maximum number of data rows is done by setting the count filter parameter. When combined with startDate this can be used to perform simple pagination. For example the first page can have a count of 100; the second page can start on the day after the last date in the first result and still have a count of 100 and so on.

Query ParameterOptionsMeaning
countInt > 0Return up to the first count rows of data (default is to return all rows available).

 
The following query will return up to 100 rows of data.

https://api.criteo.com/legacy/offsite-ads/stats/sellers?count=100

 

📘

The default is to report all rows.

 

Seller Stats

Get performance statistics aggregated for sellers.

ParameterValueMeaningDefault
intervalSizeHour, Day, Month, YearSpecify the aggregation interval for events used to compute statsDay
clickAttributionPolicy Both, SameSeller, AnySellerSpecify the click attribution policy for salesUnits, revenue, CR, CPO, COS, and ROASAnySeller
startDateDate time (YYYY-MM-DD)Filter out all events that occur before datedefault is the value of endDate
endDateDate time (YYYY-MM-DD)Filter out all events that occur after datedefault is today’s date
sellerIdIntegerShow only metrics for this Sellerdefault all Sellers
countIntegerReturn up to the first count rows of datadefault is all rows

 

https://api.criteo.com/legacy/offsite-ads/stats/sellers?intervalSize=Month
{
    "columns": ["sellerId", "sellerName", "month", "impressions", "clicks", "cost", "saleUnits", "revenue", "cr", "cpo", "cos", "roas"],
    "data": [
       [1200972, "sellerA", "2019-05-01", 14542, 48, 3.36, 0, 0.0, 0.0, null, null, 0.0],
       [1200972, "sellerA", "2019-06-01", 16619, 53, 3.71, 0, 0.0, 0.0, null, null, 0.0],
       [1200974, "sellerB", "2019-05-01", 10102, 47, 3.29, 3, 396000.0, 0.063, 1.096, 8.308E-6, 120364.741],
       [1200974, "sellerB", "2019-06-01", 11576, 54, 3.78, 1, 132000.0, 0.018, 3.78, 2.863E-5, 34920.634]
    ],
    "rows": 4
}

The seller id appears in the output in the first column and the seller name appears in the second. The time interval appears in the output as the third column. The remaining columns are metrics.

Campaign Stats

Get performance statistics aggregated for campaigns.

ParameterValueMeaningDefault
intervalSizeHour, Day, Month, YearSpecify the aggregation interval for events used to compute statsDay
clickAttributionPolicy Both, SameSeller, AnySellerSpecify the click attribution policy for salesUnits, revenue, CR, CPO, COS, and ROASAnySeller
startDateDate time (YYYY-MM-DD)Filter out all events that occur before datedefault is the value of endDate
endDateDate time (YYYY-MM-DD)Filter out all events that occur after datedefault is today’s date
sellerIdIntegerShow only metrics for this campaigndefault all campaigns
countIntegerReturn up to the first count rows of datadefault is all rows

 

https://api.criteo.com/legacy/offsite-ads/stats/campaigns?intervalSize=Month
{
   "columns": [ "campaignId", "month", "impressions", "clicks", "cost", "saleUnits", "revenue", "cr", "cpo", "cos", "roas" ],
   "data": [
       [168423, "2019-05-01", 3969032, 13410, 1111.295, 985, 190758099, 0.073, 1.128, 0.000, 171653.880 ],
       [168423, "2019-06-01", 8479603, 25619, 2190.705, 740, 152783656, 0.028, 2.960, 0.000, 69741.775 ]
       ],
   "rows": 2
}

The campaign id appears in the output as the first column. The time interval appears in the output as the second column. The remaining columns are metrics.

Seller Campaign Stats

Get performance statistics aggregated for seller campaigns.

ParameterValueMeaningDefault
intervalSizeHour, Day, Month, YearSpecify the aggregation interval for events used to compute statsDay
clickAttributionPolicy Both, SameSeller, AnySellerSpecify the click attribution policy for salesUnits, revenue, CR, CPO, COS, and ROASAnySeller
startDateDate time (YYYY-MM-DD)Filter out all events that occur before datedefault is the value of endDate
endDateDate time (YYYY-MM-DD)Filter out all events that occur after datedefault is today’s date
sellerIdIntegerShow only metrics for this campaigndefault all campaigns
countIntegerReturn up to the first count rows of datadefault is all rows

 

https://api.criteo.com/legacy/offsite-ads/stats/seller-campaigns?intervalSize=Month
{
    "columns": [
        "campaignId", "sellerId", "sellerName", "month", "impressions", "clicks", "cost", "saleUnits", "revenue", "cr", "cpo", "cos", "roas"
    ],
    "data": [
        [168423, 1110222, "118883955", "2019-05-01", 14542, 48, 3.36, 0, 0.0, 0.0, null, null, 0.0],
        [168423, 1110222, "118883955", "2019-06-01", 16619, 53, 3.71, 0, 0.0, 0.0, null, null, 0.0],
        [168423, 1110225, "117980027", "2019-05-01", 12502, 48, 3.36, 0, 0.0, 0.0, null, null, 0.0],
        [168423, 1110225, "117980027", "2019-06-01", 20266, 53, 3.71, 0, 0.0, 0.0, null, null, 0.0]
    ],
    "rows": 4
}

The campaign id, seller id, and seller name appear in the first three columns of the output. These are followed by the interval size column. The remaining columns are metrics.