Ask AI
How can we help? 👋

How to set up Google Analytics to work with your dataLayer

Google Tag Manager (GTM) rides on the information that is provided in what is called the "dataLayer" of your website. This dataLayer is a piece of data that GTM can read and use, and it follows primarily Peppered's own structure of information. This document will describe the data in the dataLayer, what it means and what data you can expect to be available there.The dataLayer is always fully available (except of course interactive events) at the start of a page load, before GTM is loaded. No data is pushed to the dataLayer, besides events, because building the dataLayer data set is done right before rendering a page.

To add GTM to you website add the Google TAG ID to the dashboard.

Go to Dashboard > System > Control Panel and look for: "Google Tag Manager"

Here you add your personal Google Tag Manager Code.

Notion image
 

Tracking interactions (events)

When you add events to your cart, we update the dataLayer, and we trigger custom "cart_add" and "cart_remove" events. Both events have an eventPayload property that contains all the properties of the item that was added or removed (see order_items in the dataLayer properties below).

Starting from release 191 we trigger "add_to_wishlist" and "remove_from_wishlist" events when events are added to or removed from the visitor's wish list. They have the same eventPayload as the cart events.

Starting from release 191, whenever the cart popup is opened we trigger an "cart_opened" event, and a "cart_closed" event when the popup is closed again.

We currently have no specific dataLayer events set up for forms.

 

dataLayer properties

cookie_consent

The choice made in the cookie consent banner between the 3 levels of agreement. (for historical reasons also available as cookieConsent)

Values:

  • "" (empty string) initial value, and equivalent for "functional cookies"; in some cases also "default"
  • limited
  • all

currency_code

An ISO 4217 currency code, e.g. "EUR".

location_category

The kind of page, or location in the website you are currently visiting.

Values:

  • error e.g. 404
  • product_list a list of events or other "things you can buy"
  • product_detail the detail page of an event, ie. a product impression
  • subscription pages to manage mailing subscriptions etc.
  • account pages related to the user account, order history etc.
  • account_signup pages related to the account signup/creation process
  • account_edit pages related to changing any properties of the account, e.g. name and address
  • checkout pages in the checkout process
  • checkout_seat_selection the user is selecting seats on the seat map
  • checkout_options the user is selecting delivery methods, donations, and other options
  • checkout_payment the user is selecting a payment method on the site
  • checkout_pending we're waiting for confirmation of payment before continuing to checkout_success
  • checkout_failed something went wrong during checkout
  • checkout_cancel the user cancelled the order
  • checkout_success the checkout was completed
  • content everything else

order_code

The box office id for an order. Is only set if an order has been registered in the box office, otherwise it's "".

order_delivery_method

The selected delivery/fulfilment method of tickets.

Values:

  • "" (empty string), initial value, nothing has been selected yet
  • postal
  • e-tickets
  • collect

order_payment_method

The payment method. During an order, multiple payment methods can be used one after the other.

For instance a voucher for part of the order amount, the rest via creditcard.Values:

  • ""(empty string), initial value, nothing has been selected yet
  • various e.g. "mollie_ideal"depending on the particular integration

order_status

An order is considered to be "started" as soon as tickets have been selected for at least one event. Until that time the user can add events to the cart, but the checkout process hasn't started yet. The selected seats are reserved for a specific period of time, the user has to finalize the order before this time runs out.

Values:

  • ""(empty string), initial value, the user hasn't started the checkout process
  • startedtickets/seats have been selected)
  • finalizedtickets are booked and payment was completed successfully

order_value

A (float) value for the total amount of the order (in the currency specified in currency_code).

visitor_is_logged_in

A boolean representing wether the user is logged in or not. If the user is logged in more information is available:

visitor_code

ID of the visitor in the box office system.

visitor_tags

List of visitor tag id’s as they are known in the box office system.

order_items

A list of the items/events in the cart/shopping basket. It's updated when a user adds or removes events. Each entry has:

  • item_category type of event: default, movie, long_termrenamed to item_category in release 178, also still available as item_type
  • item_id id of the event in the box office system renamed to item_id in release 178, also still available as item_code
  • item_name <title> hyphen <subtitle> of the production
  • item_production The production code of the event
  • item_date ISO 8601 format of the start date and time
  • products_value sum of the price of all selected tickets etc.
  • products  "products" is a list of “tickets”, ie. everything that’s part of the order item and might also include dinner tickets, 3d-glasses and other extras. If a user selects tickets for different price levels (e.g. different ranks, or tickets with discounts) each price level shows up as a different product.Each product has these values:
    • price_code id of the price in the box office system
    • price_name description of the price as it’s visible on the site
    • price_value float value of the price for one item
    • quantity number of items of this product in the orderThe extra’s (aka cross-sells) also have an “extra” value with its name.Note that the sum of "products_values" tends to end up lower than the "order_value", because the latter includes service and handling costs.

detail_items

A list of the events on the current detail page. The identifying information exactly matches that of order_items:

  • item_type
  • item_code
  • item_name
  • item_date

Additionally detail_items also have:

  • pricefloat value of the lowest price for this event
  • remarketingboolean, is true if remarketing is enabled for the production or event in the Peppered Dashboard. The remarketing value is split into two new values starting from release 175: remarketing_meta and remarketing_google.
 
Did this answer your question?
😞
😐
🤩