General Information:
- if key value is empty or missing set value to undefined or "" or -1
- begin_checkout we do not use this event as cart is one page without initial cart status so this make no sense to provide this event for further analysis use
page_view
Trigger: Trigger this event on every history change (page change)
dataLayer = window.dataLayer || [];
dataLayer.push({
event: "page_view",
page: {
info: {
name: document.title,
url: window.location.href,
path: window.location.pathname,
referrer: document.referrer,
environment: "dev" | "prod",
hostname: window.location.hostname
},
attributes: {
is_widget_embed: 'true' | 'false', // is in partner iframe
widget_id: 12312, // widget_id
widget_version: "2.0", // widget version or type if exist
host_id: 1111, // partner_id
host_name: "miastoswiatla", // hostname of partner
tags: "Impreza,Techno,Elektronika,Zagraniczne" // tags of each item
}
},
user: {
profile: {
id: 123456, // backend client_id if is known, default == undefined or ''
email: "676f42888ed8722cbdfcd8f94d951b4f739a22484bcfaa9a3d01f763cb5179ae", // sha256 email, default == undefined
type: "new" | "existing", // client has previous success purchases
crm_status: 1 | 0 // newsletter status of given email,
is_app: 0 | 1 // status of app installation for given email
},
attributes: {
lt_transactions: 11, // Int count total transactions only payment success
ltv: 1432.01, // float PLN
account_age: 24, //in months
account_created_date: "2020-01-01" // date user made first purchase
}
}
});
view_item
Trigger: Visiting event card / product detail page
ex.
☒ https://goingapp.pl/polecamy/sokol - not event page
✔ https://goingapp.pl/wydarzenie/sokol-nic-warszawa-druga-data/pazdziernik-2022 - event page
dataLayer.push({ ecommerce: null }); // Clear the previous ecommerce object.
dataLayer.push({
event: "view_item",
eventInfo: {
detail: "product detail viewed"
},
category: {
event_type: "interaction",
primary_category: "ecommerce"
},
attributes: {
is_widget_embed: 1 | 0, // (Int) is in partner iframe
widget_id: 12312, // (Int) widget_id
widget_version: 1.2, // (Float) widget version or type if exist
host_id: 1111, // (Int) partner_id
host_name: "miastoswiatla", // (String) hostname of partner
tags: "Impreza,Techno,Elektronika,Zagraniczne" // tags of each item
},
ecommerce: {
items: [{
item_id: "3182660", // (String)
item_name: "Nihiloxica • Dzuma DJ SET │ Lado w Mieście 2022 vol.7", // (String)
currency: "PLN", // (String)
index: 0, // (Int) item position on results list, starts from 0
item_brand: "Premium 2|1842", // (String) partner name | partner id
item_category: "BarKa, Warszawa, skwer im. Tadeusza Khala 1|100", // (String) venue_name|id
item_category2: "Koncert", // (String) event_category
item_category3: "Tymek", // (String) artist name
item_category4: "", // reserved for future use
item_category5: "", // reserved for future use
item_variant: 2342754, // (Int) rundate_id
price: 119.99, // (Float) gross item price
quantity: 1 // (Int) item quantity on purchase
}]
}
});
add_to_cart
Trigger: Add quantity of specific ticket into chart (each)
dataLayer.push({ ecommerce: null }); // Clear the previous ecommerce object.
dataLayer.push({
event: "add_to_cart",
eventInfo: {
detail: "add to cart",
text_displayed: "" // call to action button text
},
category: {
event_type: "interaction",
primary_category: "ecommerce"
},
attributes: {
is_widget_embed: 'true' | 'false', // widged placement going or partner iframed
widget_id: 12312, // widget_id
widget_version: "2.0", // widget version or type if exist
host_id: 1111, // partner_id
host_name: "miastoswiatla", // hostname of partner
tags: "Impreza,Techno,Elektronika,Zagraniczne" // tags of each item
},
ecommerce: {
items: [{
item_id: "3182660", // (String) Event ID
ticket_pool_id: "12345", // (String) Ticket Pool ID
item_name: "Nihiloxica • Dzuma DJ SET │ Lado w Mieście 2022 vol.7", // (String)
currency: "PLN", // (String)
index: 2, // (Int) item position on results list, starts from 0
discount: 0, // (Float) if redundant 0
coupon: "promo_abc", // (Sting) if redundant then ""
item_brand: "Premium 2|1842", // (String) partner name | partner id
item_category: "BarKa, Warszawa, skwer im. Tadeusza Khala 1|100", // (String) venue_name|id
item_category2: "Koncert", // (String) event_category
item_category3: "Tymek", // (String) artist name
item_category4: "", // reserved for future use
item_category5: "", // reserved for future use
item_variant: 2342754, // (Int) rundate_id
price: 119.99, // (Float) gross item price
quantity: 1 // (Int) item quantity on purchase
}]
}
});
remove_from_cart
Trigger: Remove quantity of specific ticket into chart (each)
dataLayer.push({ ecommerce: null }); // Clear the previous ecommerce object.
dataLayer.push({
event: "remove_from_cart",
eventInfo: {
detail: "remove from cart",
text_displayed: "" // call to action button text
},
category: {
event_type: "interaction",
primary_category: "ecommerce"
},
attributes: {
is_widget_embed: 'true' | 'false', // widged placement going or partner iframed
widget_id: 12312, // widget_id
widget_version: "2.0", // widget version or type if exist
host_id: 1111, // partner_id
host_name: "miastoswiatla", // hostname of partner
tags: "Impreza,Techno,Elektronika,Zagraniczne" // tags of each item
},
ecommerce: {
items: [{
item_id: "3182660", // (String) Event ID
ticket_pool_id: "12345", // (String) Ticket Pool ID
item_name: "Nihiloxica • Dzuma DJ SET │ Lado w Mieście 2022 vol.7", // (String)
currency: "PLN", // (String)
index: 2, // (Int) item position on results list, starts from 0
discount: 0, // (Float) if redundant 0
coupon: "promo_abc", // (Sting) if redundant then ""
item_brand: "Premium 2|1842", // (String) partner name | partner id
item_category: "BarKa, Warszawa, skwer im. Tadeusza Khala 1|100", // (String) venue_name|id
item_category2: "Koncert", // (String) event_category
item_category3: "Tymek", // (String) artist name
item_category4: "", // reserved for future use
item_category5: "", // reserved for future use
item_variant: 2342754, // (Int) rundate_id
price: 119.99, // (Float) gross item price
quantity: 1 // (Int) item quantity on purchase
}]
}
})
add_payment_info
Trigger:
dataLayer.push({ ecommerce: null }); // Clear the previous ecommerce object.
dataLayer.push({
event: "add_payment_info",
eventInfo: {
detail: "proceed to payment operator",
text_displayed: "" // call to action button text
},
category: {
event_type: "interaction",
primary_category: "ecommerce"
},
attributes: {
is_widget_embed: 'true' | 'false', // widged placement going or partner iframed
widget_id: 12312, // widget_id
widget_version: "2.0", // widget version or type if exist
host_id: 1111, // partner_id
host_name: "miastoswiatla", // hostname of partner
tags: "Impreza,Techno,Elektronika,Zagraniczne" // tags of each item
},
ecommerce: {
currency: "PLN", // (String)
value: 7.77, // (Float) total order value (incl. tax)
payment_type: "pay pal", // (String) payment method used for checkout
items: [{
item_id: "3182660", // (String) Event ID
ticket_pool_id: "12345", // (String) Ticket Pool ID
item_name: "Nihiloxica • Dzuma DJ SET │ Lado w Mieście 2022 vol.7", // (String)
currency: "PLN", // (String)
index: 2, // (Int) item position on results list, starts from 0
discount: 0, // (Float) if redundant 0
coupon: "promo_abc", // (Sting) if redundant then ""
item_brand: "Premium 2|1842", // (String) partner name | partner id
item_category: "BarKa, Warszawa, skwer im. Tadeusza Khala 1|100", // (String) venue_name|id
item_category2: "Koncert", // (String) event_category
item_category3: "Tymek", // (String) artist name
item_category4: "", // reserved for future use
item_category5: "", // reserved for future use
item_variant: 2342754, // (Int) rundate_id
price: 119.99, // (Float) gross item price
quantity: 1 // (Int) item quantity on purchase
}]
}
});
purchase - done
Trigger:
dataLayer.push({ ecommerce: null }); // Clear the previous ecommerce object.
dataLayer.push({
event: "purchase",
eventInfo: {
detail: "purchase",
text_displayed: ""
},
category: {
event_type: "interaction",
primary_category: "ecommerce"
},
attributes: {
is_widget_embed: 'true' | 'false', // widged placement going or partner iframed
widget_id: 12312, // widget_id
widget_version: "2.0", // widget version or type if exist
host_id: 1111, // partner_id
host_name: "miastoswiatla", // hostname of partner
tags: "Impreza,Techno,Elektronika,Zagraniczne" // tags of each item
},
ecommerce: {
transaction_id: "T_12345", // (String) transaction_id
value: 25.42, // (Float) total order value (tax and shipping incl.)
tax: 4.90, // (Float) tax value
shipping: 0, // (Float)
currency: "PLN", // (String)
coupon: "", // (String) if redundant then ""
items: [{
item_id: "3182660", // (String) Event ID
ticket_pool_id: "12345", // (String) Ticket Pool ID
item_name: "Nihiloxica • Dzuma DJ SET │ Lado w Mieście 2022 vol.7", // (String)
currency: "PLN", // (String)
index: 2, // (Int) item position on results list, starts from 0
discount: 0, // (Float) if redundant 0
coupon: "promo_abc", // (Sting) if redundant then ""
item_brand: "Premium 2|1842", // (String) partner name | partner id
item_category: "BarKa, Warszawa, skwer im. Tadeusza Khala 1|100", // (String) venue_name|id
item_category2: "Koncert", // (String) event_category
item_category3: "Tymek", // (String) artist name
item_category4: "", // reserved for future use
item_category5: "", // reserved for future use
item_variant: 2342754, // (Int) rundate_id
price: 119.99, // (Float) gross item price
quantity: 1 // (Int) item quantity on purchase
}]
}
});
proceed - done
Trigger_1: Proceed from event_page to checkout (hit in CTA ‘Kup Bilet’ or ‘Kup Karnet’ etc)
Trigger_2: Proceed from event_page to checkout (hit in CTA ‘Wybierz’)
dataLayer.push({
event:"proceed",
eventInfo:{
detail:"proceed to checkout"| "set reminder" |"other events" |"add event to wishlist",
text_displayed: "kup bilet" | "wybierz" | "kup karnet"| "powiadom mnie"| "przypomnij mi" | "daj znać, jak się pojawią ponownie" | "śledź kolejne wydarzenia artysty/promotora/miejsca" | "dodaj do kalendarza"
},
category:{
event_type: "interaction",
primary_category: "transaction"
},
attributes:{
destination_url: "<https://goingapp.pl/kup-bilety/koncert-chopinowski-w-sali-koncertowej-fryderyk-408/wrzesien-2022>",
tags: "Impreza,Techno,Elektronika,Zagraniczne" // tags of each item
},
transaction:{
type: "buy"
}
});
Auto fill data on checkout
Trigger: onClick ‘uzupełnij danymi’
dataLayer.push({
event:"interaction",
eventInfo:{
detail:"checkout",
text_displayed: "uzupelnij danymi"
},
category:{
event_type: "interaction",
primary_category: "checkout"
}
});
deeplink_web
Trigger:
dataLayer.push({
event:"interaction",
eventInfo:{
detail:"choose service version",
text_displayed: "wybierz" | "kontyynuuj" // (String)
},
category:{
event_type: "interaction",
primary_category: "product_page"
},
attributes:{
destination_url: "<https://goingapp.pl/wydarzenia>", // (String) destination URL
destination_type: "app" | "web" // (String)
}
})