This guide is intended for merchants who need to add basket information to an existing integration.
Manual installation
In the confirmation tag you need to add a basket parameter in the _kkstrack variable, with the following format
_kkstrack = {
...
basket: [{ productname: 'Man@@ubri ricoperti di spugna 1 kg x 2 pz ',
productid: '1',
quantity: '1',
price: '4.2'
},
{ productname: 'p2',
productid: '2',
quantity: '3',
price: '8.6'
},
...
]
...
};
All fields are mandatory
productid need to be a unique identifier for the product. Use the same as the one you've defined in your offer feed, whether it's EAN, SKU or an other id. If they are different we won't be able to unlock some performance optimisations.
Installation via GTM
In your datalayer, you need to add a transactionProducts variable with the following format
window.dataLayer = window.dataLayer || [];
dataLayer.push({
'transactionId':'1234',
'transactionAffiliation':'Acme Clothing',
'transactionTotal':38.26,
'transactionTax':1.29,
'transactionShipping':5,
'transactionProducts':[{
'sku':'DD44',
'name':'T-Shirt',
'category':'Apparel',
'price':11.99,
'quantity':1},
{
'sku':'AA345',
'name':'Boots',
'category':'Shoes',
'price':99.99,
'quantity':4
}]
})
All fields are mandatory.
sku needs to a unique identifier for the product. Use the same as the one you've defined in your offer feed, whether it's EAN, SKU or an other id. If there are different we won't be able to unlock some performance optimisation.
How to pass ProductId / SKU information to Kelkoo Sales Tracking
-
For an installation via Google Tag Manager (GTM), add SKU in the GTM tag
-
For a Manual Installation, add SKU to js variable _kkltrack (_kkltrack.sku)
-
If you already follow Google requirements regarding structured product metada (https://developers.google.com/search/docs/data-types/product#microdata ), Kelkoo Sales Tracking will retrieve them automatically
Ex:
<meta itemprop="sku" content="0446310786" />
<div property="schema:sku" content="0446310786"></div>
<script type="application/ld+json">
{
...
"sku": "0446310786",
...
}
</script>
-
Kelkoo Sales Tracking also supports Google Analytics baskets
[
{
"id": "P12345",
"name": "Android Warhol T-Shirt",
"list_name": "Search Results",
"brand": "Google",
"category": "Apparel/T-Shirts",
"variant": "Black",
"list_position": 1,
"quantity": 2,
"price": '2.0'
},
{
"id": "P67890",
"name": "Flame challenge TShirt",
"list_name": "Search Results",
"brand": "MyBrand",
"category": "Apparel/T-Shirts",
"variant": "Red",
"list_position": 2,
"quantity": 1,
"price": '3.0'
}
]