Within each item
item_name
is the product name.item_category
is the offer name.
Within each ecommerce object
value
is always the total value of the items (price * quantity).
Examples below are the logged events in Google Tag Manager. To test them, see How to debug and test your connection.
dataLayer.push({
event: "view_item",
ecommerce: {
items: [
{
item_id: "18446",
item_name: "Donate €1",
price: 1,
item_category: "Donatie"
},
{
item_id: "18447",
item_name: "Donate €2",
price: 2,
item_category: "Donatie"
},
{
item_id: "18448",
item_name: "Donate €5",
price: 5,
item_category: "Donatie"
},
{
item_id: "18449",
item_name: "Donate €10",
price: 10,
item_category: "Donatie"
}
]
},
gtm.uniqueEventId: 10
})
dataLayer.push({
event: "add_to_cart",
ecommerce: {
currency: "EUR",
value: 6,
items: [
{item_id: "2524169", item_name: "Donate €1", price: 1, item_category: "Donatie", quantity: 1},
{item_id: "2524170", item_name: "Donate €5", price: 5, item_category: "Donatie", quantity: 1}
]
},
gtm.uniqueEventId: 11
})
dataLayer.push({
event: "remove_from_cart",
ecommerce: {
currency: "EUR",
value: 1,
items: [
{item_id: "2524169", item_name: "Donate €1", price: 1, item_category: "Donatie", quantity: 1}
]
},
gtm.uniqueEventId: 12
})
This step is triggered when a customer starts the initial checkout

dataLayer.push({
event: "begin_checkout",
ecommerce: {
currency: "EUR",
value: 5,
items: [
{item_id: "2524172", item_name: "Donate €5", price: 5, item_category: "Donatie", quantity: 1}
]
},
gtm.uniqueEventId: 13
})
Note
value
is the total amount of the basket (incl. discounts and service fees).
dataLayer.push({
event: "add_payment_info",
ecommerce: {currency: "EUR", value: 5, payment_type: "scheme", items: []},
gtm.uniqueEventId: 14
})
payment_type
is ‘scheme’ when a creditcard is being used, other possible values are bcmc_mobile, giftcard, banktransfer, paysafecard, etc…items
are always empty here.
dataLayer.push({
"event": "purchase",
"ecommerce": {
"transaction_id": "D88SO9A4VUCEQ",
"value": 14, // value = (quantity x sale price) - basket discount (€5) => 19 - 5 => 14
"currency": "EUR",
"items": [
{
"item_id": "3078243",
"item_name": "Adult ticket",
"price": 19, // The sale price is the per item list price (20.00) minus discount (1.00),
"discount": 1 // The discount per item
"item_category": "Swimming - all day",
"quantity": 1
}
]
},
"gtm.uniqueEventId": 17
})
transaction_id
corresponds to the order number in Enviso.value
is the total amount of the basket (incl. discounts and service fees).
dataLayer.push({
event: "refund",
ecommerce: {transaction_id: 19196, currency: "EUR", value: 1},
gtm.uniqueEventId: 10
})
dataLayer.push({
event: "view_cart",
ecommerce: {
currency: "EUR",
value: 2,
items: [
{item_id: "2524250", item_name: "Donate €1", price: 1, item_category: "Donatie", quantity: 2}
]
},
gtm.uniqueEventId: 13
})
dataLayer.push({
event: "select_promotion",
ecommerce: {
promotion_id: "SUMMER2023",
items: [
{item_id: "2524250", item_name: "Donate €1", price: 1, item_category: "Donatie", quantity: 2}
]
},
gtm.uniqueEventId: 14
})
promotion_id
is the discount code.
dataLayer.push({event: "login", ecommerce: {method: "login"}, gtm.uniqueEventId: 9})
dataLayer.push({event: "login", ecommerce: {method: "signup"}, gtm.uniqueEventId: 10})