Discard

Criteo Marketing Solutions API

Questions

Ask A Question
0

API Response coming in a different language

Hi, this is regarding Criteo API Response not coming in the English language, even after passing the right language headers. Just wanted to confirm if this is an issue from criteo's end and if there is any way to localise the API response? Request Headers Content-Type:"application/json; charset=UTF-8", Accept-Charset:"utf-8, iso-8859-1;q=0.7", Accept-Language:"en-US,en;q=0.5", user-agent:"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/89.0.4389.114 Safari/537.36"] Criteo Response Response received from Service:<200,笀਀  ∀洀攀琀愀搀愀琀愀∀㨀 笀਀    ∀琀漀琀愀氀䤀琀攀洀猀䄀挀爀漀猀猀䄀氀氀倀愀最攀猀∀㨀 ㈀Ⰰ਀    ∀挀甀爀爀攀渀琀倀愀最攀匀椀稀攀∀㨀 ㈀Ⰰ਀    ∀挀甀爀爀攀渀琀倀愀最攀䤀渀搀攀砀∀㨀  Ⰰ਀    ∀琀漀琀愀氀倀愀最攀猀∀㨀 ㄀਀  紀Ⰰ਀  ∀搀愀琀愀∀㨀 嬀਀    笀਀      ∀椀搀∀㨀 ∀㜀㜀㌀㌀㐀㘀㜀 ∀Ⰰ਀      ∀琀礀瀀攀∀㨀 ∀刀攀琀愀椀氀䴀攀搀椀愀倀爀漀洀漀琀攀搀倀爀漀搀甀挀琀∀Ⰰ਀      ∀愀琀琀爀椀戀甀琀攀猀∀㨀 笀਀        ∀戀椀搀伀瘀攀爀爀椀搀攀∀㨀  ⸀㔀       ਀      紀਀    紀Ⰰ਀    笀਀      ∀椀搀∀㨀 ∀㜀㜀㌀㌀㐀㘀㘀㜀∀Ⰰ਀      ∀琀礀瀀攀∀㨀 ∀刀攀琀愀椀氀䴀攀搀椀愀倀爀漀洀漀琀攀搀倀爀漀搀甀挀琀∀Ⰰ਀      ∀愀琀琀爀椀戀甀琀攀猀∀㨀 笀਀        ∀戀椀搀伀瘀攀爀爀椀搀攀∀㨀  ⸀㔀       ਀      紀਀    紀਀  崀਀紀,[date:"Mon, 02 Aug 2021 05:49:14 GMT", content-type:"application/json; charset=utf-16", server:"Kestrel", content-length:"874", access-control-expose-headers:"X-JWT-Token", link:"<https://api.criteo.com/preview/retail-media/line-items/193293755391266816/products?pageIndex=0&pageSize=2>; rel=first,<https://api.criteo.com/preview/retail-media/line-items/193293755391266816/products?pageIndex=0&pageSize=2>; rel=last", x-jwt-token:"Bearer eyJhbGciOiJSUzI1NiIsImtpZCI6Ilg1YUQ1YmpiOWF3cUM1Z3ZXNTJidkRoRE1BTFJIOVRCZHh6SjloQnlvNU0iLCJ0eXAiOiJKV1QifQ.eyJleHAiOjE2Mjc5Njk3NTMsImlhdCI6MTYyNzg4MzM1MywiaXNzIjoiY3JpdGVvLWNlcmJlcnVzIiwiY3R4OmFwcGxpY2F0aW9uOmlkIjoiMTczNiIsImF1ZCI6ImNyaXRlby1hcGlnYXRld2F5IiwiY3R4OnVzZXI6ZW1haWwiOiJhcGktcHJvZ3JhbS11c2VyQDRkOTBjZWIzMDdkNDRlNzM4ZDBmYmY0ODI1Mzk1ZjE2LmNvbSIsImN0eDphcHBsaWNhdGlvbjpuYW1lIjoiQ29tbWVyY2VJUSIsImFkZDptYXBpOnVuYW1lIjoiYXBpLXByb2dyYW0tdXNlci00ZDkwY2ViMzA3ZDQ0ZTczOGQwZmJmNDgyNTM5NWYxNiIsImN0eDp1c2VyOnVpZCI6InVtczphcGktcHJvZ3JhbS11c2VyLTRkOTBjZWIzMDdkNDRlNzM4ZDBmYmY0ODI1Mzk1ZjE2IiwiY3R4OnVzZXI6dW1zSWQiOiIzNzc0MjIiLCJjdHg6dXNlcjpkaXNwbGF5TmFtZSI6ImFwaS1wcm9ncmFtLXVzZXItNGQ5MGNlYjMwN2Q0NGU3MzhkMGZiZjQ4MjUzOTVmMTYiLCJjdHg6b3JnYW5pemF0aW9uOm5hbWUiOiJDb21tZXJjZUlRIiwiY2xpZW50X2lkIjoiZWYyOWNmZDYyMWE4NDY5MGFkOTY1ZmR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it:"100", x-ratelimit-remaining:"99"]>

Posted by Ishank S 2 months ago

1
ANSWERED

statistics/report returns two objects for the same list of dimensions

Hello! We execute a request to statistics report: curl -X POST --data '{ "advertiserIds":"<advertiser_id>", "endDate":"2021-07-25", "format":"Json", "currency":"EUR", "metrics":[ "AdvertiserCost", "SalesAllClientAttribution", "RevenueGeneratedAllClientAttribution" ], "startDate": "2021-07-01", "dimensions": [ "AdsetID", "Category", "Day" ]}' -H 'Authorization: Bearer <auth_token>' -H 'Content-Type: application/json' -H 'Accept: application/octet-stream' -A 'Jersey/2.31' 'https://api.criteo.com/2021- 01/statistics/report' And we've noticed that the report has two objects for the same list of dimensions. For example: { "AdsetId": "<adset_id>", "Adset": "<adset_name>", "CategoryId": "0", "Category": "", "Day": "2021-07-04", "Currency": "EUR", "AdvertiserCost": "1.6", "SalesAllClientAttribution": "0", "RevenueGeneratedAllClientAttribution": "0" }, { "AdsetId": "<adset_id>", "Adset": "<adset_name>", "CategoryId": "0", "Category": "", "Day": "2021-07-04", "Currency": "EUR", "AdvertiserCost": "90.0163", "SalesAllClientAttribution": "7", "RevenueGeneratedAllClientAttribution": "371.31" } Here, we have two objects with the same AdsetId, Adset, CategoryId, Day. But we have different values for AdvertiserCost, SalesAllClientAttribution and RevenueGeneratedAllClientAttribution. Why do we have more one object for requested dimensions? We cannot sum them, since the report contains averages (Average cart).

Posted by Nina 2 months ago

2
ANSWERED

how to check x-criteo-hmac-sha512 ,do you have any example

original text: The callback request will also include an HTTP header named x-criteo-hmac-sha512 . Its value will be the HMAC-SHA512 hash of the callback request body, using the same signing secret value as your app. come from url: https://developers.criteo.com/marketing-solutions/docs/criteo-connector-implementation-guide. my callback request body is: {"Type":"ConsentGranted","Data":{"Key":"321*****bdd","Timestamp":1626764122,"State":"63759","ApplicationId":1****,"ApplicationName":"****m","RequestedScopes":[{"AccessLevel":"Read","Domain":"Campaign","CriteoService":"MarketingSolutions"},{"AccessLevel":"Read","Domain":"Audience","CriteoService":"MarketingSolutions"},{"AccessLevel":"Read","Domain":"Analytics","CriteoService":"MarketingSolutions"},{"AccessLevel":"Read","Domain":"Catalog","CriteoService":"MarketingSolutions"}],"AcceptedScopes":[{"AccessLevel":"Read","Domain":"Campaign","CriteoService":"MarketingSolutions"},{"AccessLevel":"Read","Domain":"Audience","CriteoService":"MarketingSolutions"},{"AccessLevel":"Read","Domain":"Analytics","CriteoService":"MarketingSolutions"},{"AccessLevel":"Read","Domain":"Catalog","CriteoService":"MarketingSolutions"}],"Advertisers":[{"Id":"6*****","Name":"M******"}]}} x-criteo-hmac-sha512 value (at HTTP header ) not match with the HMAC-SHA512 hash of upper json .and i don't know what's wrong with this code. my code is below: var criteoHmacSha512 = Request.Headers["x-criteo-hmac-sha512"].ToString(); var requestBody = JsonConvert.SerializeObject(criteoContentCallbackRequestBoday), var requestBodySigned=HmacUtil.Sign(requestBody , Encoding.UTF8.GetBytes(_configInfo.CriteoSigningKeySecret)) if (criteoHmacSha512 != requestBodySigned) { return false; } …… please help me if you know the answer ,thanks a lot

Posted by Laraine Xi 3 months ago