Skip to main content

Ad Set SKU-Level Metrics API

This section provides detailed information about the Ad Set SKU-Level Metrics API in Retail Media Reporting.

Overview

The Ad Set SKU-Level Metrics API retrieves SKU-level metrics for ad sets, providing granular performance data per product SKU. This API helps you track and analyze the effectiveness of your advertising sets across various placements and products over a specific date range.

Authentication

This API uses OAuth 2.0 client credentials flow for authentication. See the Authentication section for detailed instructions.

API Endpoint

Method: GET

URL: {BASE_URL}/retail-media/supplier/{supplierId}/retailers/{retailerId}/campaign/{campaignId}/adset-sku-level-metrics

Path Parameters

ParameterTypeDescription
supplierIdstringThe supplier identifier
retailerIdstringThe retailer identifier
campaignIdstringThe campaign identifier

Query Parameters

ParameterTypeRequiredDescription
fromDatestringYesStart date in YYYY-MM-DD format
toDatestringYesEnd date in YYYY-MM-DD format
pagenumberNoPage number for pagination

Request Headers

Authorization: Bearer {access_token}
Content-Type: application/json

Response

Success Response

Status Code: 200 OK

{
"status": "success",
"message": "SKU-level metrics retrieved successfully",
"errorCode": "",
"data": [
{
"date": "2024-03-15",
"supplierId": "supplier_123",
"supplierName": "Acme Corporation",
"campaignId": "campaign_789",
"campaignName": "Spring Sale Campaign",
"adSetId": "adset_456",
"adSetName": "Ad Set 1",
"placementId": "placement_789",
"placementName": "Homepage Banner",
"adSetType": "Sponsored",
"adSetStrategy": "Auto",
"costType": "CPC",
"productId": "product_123",
"refId": "ref_456",
"sku": "SKU-XYZ-1",
"bannerId": "banner_123",
"spend": 500.25,
"discount": 25.00,
"impression": 5000,
"clicks": 150,
"sponsoredUnits": 10,
"sponsoredRevenue": 750.00,
"reach": 4500,
"frequency": 1.11
}
],
"pagination": {
"currentPage": 1,
"totalPages": 1,
"totalRecords": 1,
"pageSize": 100
},
"metadata": {}
}

Available Metrics

The Ad Set SKU-Level Metrics API provides comprehensive data about your ad sets at the SKU level, including performance indicators and financial metrics. Here's a detailed breakdown of the available metrics:

MetricDescriptionTypeAggregation
dateDate of the ad set running period (YYYY-MM-DD)stringDate Range
supplierIdID of the supplierstringDate Range
supplierNameName of the supplierstringDate Range
campaignIdID of the campaignstringDate Range
campaignNameName of the campaignstringDate Range
adSetIdID of the ad setstringDate Range
adSetNameName of the ad setstringDate Range
placementIdID of the placementstringDate Range
placementNameName of the placementstringDate Range
adSetTypeType of the ad set (Sponsored, Sponsored Search, Sponsored Product, Sponsored Display)stringDate Range
adSetStrategyStrategy of the ad set (Auto, Relevance, Hybrid, Bid)stringDate Range
costTypeCost type (CPC, CPM, CPA)stringDate Range
productIdPA generated ID of the product (optional)stringDate Range
refIdUnique identifier of the product (optional)stringDate Range
skuSKU of the product (optional)stringDate Range
bannerIdBanner identifier (optional)stringDate Range
spendAmount spent for the ad set on that datenumberDate Range
discountDiscount amount applied on that datenumberDate Range
impressionNumber of times the product was displayed on that datenumberDate Range
clicksNumber of clicks received on that datenumberDate Range
sponsoredUnitsNumber of units sold through sponsored ads on that datenumberDate Range
sponsoredRevenueRevenue attributed to the sponsored product on that datenumberDate Range
reachFor sponsored display, number of unique visitors who viewed the bannernumberDate Range
frequencyFor sponsored display, ratio of impressions to unique visitorsnumberDate Range

Understanding the Metrics

The Ad Set SKU-Level Metrics provide insights into various aspects of your ad set performance at the product level:

Performance Metrics

  • Impressions: Total number of times your products were displayed on a specific date
  • Clicks: Total number of clicks received on a specific date
  • Reach: Number of unique visitors who viewed the banner (for sponsored display)
  • Frequency: Ratio of impressions to unique visitors (for sponsored display)

Financial Metrics

  • Spend: Total amount spent on the ad set on a specific date
  • Discount: Discount amount applied on a specific date
  • Cost Type: The pricing model used (CPC, CPM, CPA)

Sales Metrics

  • Sponsored Units: Number of units sold through sponsored ads on a specific date
  • Sponsored Revenue: Total revenue attributed to the sponsored product on a specific date

Product Information

  • Product ID: PA generated identifier for the product
  • Reference ID: Unique identifier of the product
  • SKU: Stock keeping unit of the product
  • Banner ID: Identifier for the banner (for display ads)

Example Usage (JavaScript)

// First, obtain an access token using OAuth 2.0 client credentials flow
const getAccessToken = async () => {
const response = await fetch('{BASE_URL}/connect/token', {
method: 'POST',
headers: {
'Content-Type': 'application/x-www-form-urlencoded',
},
body: new URLSearchParams({
client_id: 'YOUR_CLIENT_ID',
client_secret: 'YOUR_CLIENT_SECRET',
grant_type: 'client_credentials'
})
});

const data = await response.json();
return data.access_token;
};

// Then, make the API request
const getAdSetSkuLevelMetrics = async () => {
const accessToken = await getAccessToken();

const response = await fetch(
'{BASE_URL}/retail-media/supplier/{supplierId}/retailers/{retailerId}/campaign/{campaignId}/adset-sku-level-metrics?fromDate=2024-03-01&toDate=2024-03-31&page=1',
{
method: 'GET',
headers: {
'Authorization': `Bearer ${accessToken}`,
'Content-Type': 'application/json'
}
}
);

const data = await response.json();
console.log(data);
};

Best Practices

  1. Daily Monitoring: Check SKU-level metrics daily to ensure optimal performance
  2. Performance Analysis: Use impressions and clicks to optimize product visibility
  3. Revenue Tracking: Monitor sponsored revenue to ensure product-level profitability
  4. Budget Management: Track spend against performance metrics on a daily basis
  5. Product Performance: Analyze which SKUs perform best in different placements
  6. Placement Optimization: Use placement data to optimize product positioning
  7. Date Range Analysis: Compare performance across different date ranges to identify trends
  8. SKU-Level Optimization: Use granular data to optimize individual product performance
  9. Cost Efficiency: Monitor cost types and strategies to optimize spending
  10. Pagination: Use pagination parameters to handle large datasets efficiently