1. Benefits of Using Google Tag Manager
Simplified Tracking
Minimal code changes after initial GTM installation
Quick setup and modification of tracking tags (via GTM)
Reduced dependency on developers
Visual interface for tag management
Centralized Control
Single platform for all tracking tags
Version control and change history
Easy updates across entire website
Consistent implementation across pages
Team collaboration features
Additional Advantages
Speed: Faster implementation of marketing tags
Testing: Built-in preview and debug mode
Security: Reduced risk of code errors
Flexibility: Easy integration with multiple platforms
Compliance: Better control over data collection
2. Prerequisites
Before starting, make sure you have:
A Google Tag Manager Web container (or permission to create/edit one)
A GA4 property and your Measurement ID (format:
G-XXXXXXXXXX)Access to your website code/CMS to install GTM across all pages
(Recommended) A consent banner / Consent Mode setup if you operate in regulated regions
3. Tracking Process Overview
Data Flow Architecture
Customer Action: User interacts with Smeetz widget
Event Generation: E-commerce object created in booking flow
Data Transmission: Object sent to your website
Data Layer: Objects queued in GTM's
dataLayerTag Processing: GTM processes and forwards to destinations
4. Tracked Events
The events below are the Smeetz dataLayer format that Smeetz sends to your website’s Google Tag Manager (GTM). This format is not the same as the native event/payload format expected by platforms like Google Analytics 4 (GA4) or Meta.
In practice, you use GTM to read these Smeetz events (as they arrive in the dataLayer), then map/transform the data into the destination platform’s expected structure and finally send it to GA4, Meta, or any other tool you use.
Important: Some events can contain personally identifiable information (PII) (for example smtz_user_identity can include an email address). Do not forward plaintext PII to GA4 (GA policies prohibit sending PII). Use GTM to either (a) avoid sending those fields to GA4, or (b) hash/transform data only where your destination platform and legal basis allow it.
widget-button-click
When it triggers: When the user clicks the widget button (Book button) to open the booking iframe.
What you receive: A minimal event-only payload.
{
"event": "widget-button-click"
}smtz_user_identity
When it triggers: When a user is identified in the flow. This can happen (1) right after a user logs in or registers, (2) immediately when the widget opens if the user is already logged in (session remembered), and (3) again later in the flow (it can be emitted more than once, for example close to the final confirmation where
smtz_purchaseis sent).What you receive: A user identity payload in
smeetzData. At minimum this includesemail, and it can also includefirstname/lastnamewhen available. Treat this payload as PII and only forward what you need.
{
"event": "smtz_user_identity",
"smeetzLabel": "<user_email>",
"smeetzCategory": "user_identity",
"smeetzAction": "Identify user",
"smeetzData": {
"email": "<user_email>",
"firstname": "<first_name>",
"lastname": "<last_name>"
}
}smtz_view_item_list
When it triggers: When the user reaches the ticket list (first time they see the available items/tickets for a product).
What you receive: The viewed product/item in
smeetzData(as an array of items) to support GA4view_item_listtracking.
{
"event": "smtz_view_item_list",
"smeetzLabel": "<product_name>",
"smeetzCategory": "ecommerce",
"smeetzAction": "view Item List",
"smeetzData": [
{
"id": "<product_id>",
"name": "<product_name>",
"currency": "<currency>",
"brand": "<brand>",
"quantity": 1
}
]
}smtz_dynamicPricing_enabled
When it triggers: When dynamic pricing is enabled for the current user/product (this can be sent before the normal e-commerce events to flag the session).
What you receive: A flag-style event using the same e-commerce structure so you can segment or enrich downstream tracking in GTM.
{
"event": "smtz_dynamicPricing_enabled",
"smeetzLabel": "<product_name>",
"smeetzCategory": "ecommerce",
"smeetzAction": "view Item List",
"smeetzData": [
{
"id": "<product_id>",
"name": "<product_name>",
"currency": "<currency>",
"brand": "<brand>",
"quantity": 1
}
]
}smtz_remove_from_cart
When it triggers: When the user removes a ticket/item from the cart.
What you receive: The removed item in
smeetzData(as an array of items).
{
"event": "smtz_remove_from_cart",
"smeetzLabel": "<product_name>",
"smeetzCategory": "ecommerce",
"smeetzAction": "Remove From Cart",
"smeetzData": [
{
"id": "<ticket_name>",
"name": "<product_name>",
"currency": "<currency>",
"brand": "<brand>",
"price": 0,
"quantity": 1
}
]
}
smtz_view_cart
When it triggers: When the user opens/views the cart (basket) screen.
What you receive: The current cart content in
smeetzData(as an array of items).
{
"event": "smtz_view_cart",
"smeetzLabel": "<product_name>",
"smeetzCategory": "ecommerce",
"smeetzAction": "View Cart",
"smeetzData": [
{
"id": "<item_id>",
"name": "<ticket_name>",
"currency": "<currency>",
"brand": "<brand>",
"category": "<ticket_name>",
"price": 0,
"quantity": 1
}
]
}
smtz_add_to_cart
When it triggers: When the customer adds a ticket/item to the cart.
What you receive: The added item in
smeetzData(as an array of items) and atransactionId(booking reference).
{
"event": "smtz_add_to_cart",
"smeetzLabel": "<product_name>",
"smeetzCategory": "ecommerce",
"smeetzAction": "Add to cart",
"transactionId": "<booking_ref>",
"smeetzData": [
{
"id": "<ticket_id>",
"name": "<ticket_name>",
"currency": "<currency>",
"brand": "<brand>",
"price": 0,
"quantity": 1,
"discount": 0
}
]
}smtz_begin_checkout
When it triggers: When the customer starts the checkout process (moves from cart to checkout).
What you receive: The current cart items in
smeetzData(as an array of items) and atransactionId(booking reference).
{
"event": "smtz_begin_checkout",
"smeetzLabel": "<product_name>",
"smeetzCategory": "ecommerce",
"smeetzAction": "Begin Checkout",
"transactionId": "<booking_ref>",
"smeetzData": [
{
"id": "<item_id>",
"name": "<ticket_name>",
"currency": "<currency>",
"brand": "<brand>",
"category": "<ticket_name>",
"price": 0,
"quantity": 1,
"discount": 0
}
]
}smtz_checkout_progress
When it triggers: When the customer advances through the checkout steps (progress within the checkout flow).
What you receive: The current checkout items in
smeetzData(as an array of items) and atransactionId(booking reference).
{
"event": "smtz_checkout_progress",
"smeetzLabel": "<product_name>",
"smeetzCategory": "ecommerce",
"smeetzAction": "Checkout progress",
"transactionId": "<booking_ref>",
"smeetzData": [
{
"id": "<item_id>",
"name": "<ticket_name>",
"currency": "<currency>",
"brand": "<brand>",
"category": "<ticket_name>",
"price": 0,
"quantity": 1,
"discount": 0
}
]
}smtz_payment_info
When it triggers: When the customer reaches/submits payment information during checkout.
What you receive: The current checkout items in
smeetzData(as an array of items), a transactionId (booking reference), and avaluerepresenting the booking total at that stage.
{
"event": "smtz_payment_info",
"smeetzLabel": "<product_name>",
"smeetzCategory": "ecommerce",
"smeetzAction": "Add payment Info",
"transactionId": "<booking_ref>",
"smeetzData": [
{
"id": "<item_id>",
"name": "<ticket_name>",
"currency": "<currency>",
"brand": "<brand>",
"category": "<ticket_name>",
"price": 0,
"quantity": 1,
"discount": 0
}
],
"value": 0
}smtz_purchase
When it triggers: When the booking is completed successfully (purchase/confirmation).
What you receive: The purchased items in
smeetzData(as an array of items), atransactionId(booking reference), and avaluerepresenting the total. This event can also include customer fields that are already hashed (SHA-256) such ascustomerEmail,customerFirstName,customerLastName, andcustomerPhoneNumber.
{
"event": "smtz_purchase",
"smeetzLabel": "<product_name>",
"smeetzCategory": "ecommerce",
"smeetzAction": "Purchase",
"smeetzData": [
{
"id": "<item_id>",
"name": "<ticket_name>",
"currency": "<currency>",
"brand": "<brand>",
"price": 0,
"quantity": 1,
"category": "<ticket_name>",
"discount": 0
}
],
"transactionId": "<booking_ref>",
"value": 0,
"customerEmail": "<sha256_email_hex>",
"customerFirstName": "<sha256_first_name_hex>",
"customerLastName": "<sha256_last_name_hex>",
"customerPhoneNumber": "<sha256_phone_hex>"
}
5. Implementation Steps
Step 1: Install the GTM snippet on your website (required)
This step is required so GTM can receive and process the dataLayer events.
In Google Tag Manager, go to Admin → Install Google Tag Manager (or click your container ID at the top).
Copy the two snippets shown by GTM: Script snippet: paste it inside the
<head>section. NoScript snippet: paste it immediately after the opening<body>tag.Install the snippets on all pages where the widget can be used (including subdomains if applicable).
Verify installation: Open your website and use Tag Assistant / Preview mode in GTM. Confirm the container loads and you can see
dataLayerevents coming in.
Note: Don’t rewrite the snippet manually. Always copy it from the GTM UI to avoid typos.
Step 2: Insert GTM ID in Smeetz Back Office
Log into Smeetz back office
Navigate to Integrations section
Locate GTM/Google Tag Manager field
Enter your GTM Container ID (format:
GTM-XXXXXXX)Save changes
Step 3: Import JSON Container in GTM
Access Google Tag Manager
Click Admin → Import Container
Upload the provided JSON file
Select Merge or Overwrite as needed
Confirm import
Step 4: Configure GA4 Measurement ID
After importing the GTM container, you must set your GA4 Measurement ID:
Go to Variables in Google Tag Manager
Search for the variable named Measurement ID
Open it and replace the value with your GA4 Measurement ID (format:
G-XXXXXXXXXX)Save changes
Step 5: Test in GTM Preview before publishing (recommended)
In GTM, click Preview and connect it to your website.
Open the widget and run a test booking flow.
Confirm you see Smeetz events in the GTM preview timeline (for example
smtz_view_item_list,smtz_add_to_cart,smtz_purchase).Confirm your GA4 tags fire and events appear in GA4 Realtime.
Step 6: Publish the GTM container
In GTM, click Submit → Publish.
(Recommended) Add a short version name like
Smeetz GA4 ecommerce setup.


