Skip to content

at-internet/gtm-pa-tagging

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

53 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Piano Analytics GTM template for tagging

This template is meant to be used in combination with Piano Analytics configuration template.

Installation

Add both templates from the Gallery to your Workspace.

Tag template gallery

Setup

Variable (configuration)

Create a new Variable based on the Piano Analytics - Configuration template.

New variable type

Fill your collection endpoint, site number, PA SDK source (up to date CDN file by default) and choose the default consent mode.

Variable configuration

You can configure your Consent settings (documentation).

Consent configuration

You can also add any other configuration available with our JS SDK (documentation).

Other SDK configuration

Tag

Create a new Tag based on the Piano Analytics - Tagging template.

New tag type

Make sure you use the previously created Variable as the Configuration for the Tag.

You can now choose the action you need this tag to achieve.

Send an event

Documentation

Fill the Event name and all the properties needed.

Tag configuration

Send multiple events

Documentation

For each event to be sent, fill the Event name and give a variable with an object of properties to be sent.

Send multiple events

The event properties object can either be a JS Variable, or a custom JS Variable.

Custom JS Variable

eCommerce bridge

Documentation

The template offers a native GA eCommerce bridge, that will automatically transform GA eCommerce tagging to Piano Analytics events and properties.

Events mapping

Default events mapping is displayed directly in the tag configuration.

Default ecommerce events mapping

Properties mapping

Default properties mapping is displayed directly in the tag configuration.

Default ecommerce properties mapping

You can customize the properties mapping by adding new lines. Each line describes one mapping.

  1. The first field expects the Datalayer property name. You can prefix the value with $$ to give a value instead of a property name.
  2. The second field expects the Piano Analytics property to fill with the output.

Custom ecommerce properties mapping

Set properties

Documentation

You can set properties to subsequent events.

Set properties

You can set the type of the property to either a fixed type, or to let the template automatically detect the type (using JSON.parse JS method).

Set property type

Set a user

Documentation

You can user this action to identify a logged in user.

Set a user

Set a Consent mode

Documentation

You can set a new Consent mode if the end-user changes its preferences.

Set consent mode

Set a Privacy mode (deprecated)

Documentation

You can set a new Privacy mode if the end-user changes its preferences.

Set privacy mode

Override the Visitor ID (not recommended)

Documentation

You can override our SDK management of the Visitor ID. This is however not recommended.

Set a visitor ID

Releases

No releases published

Packages

No packages published