Reusing Enhanced ecommerce datalayer variables

Reusing Enhanced ecommerce datalayer variables

This guide will help to reuse existing Google Analytics EEC Purchase data-layers for other marketing pixels /tags (like Facebook Pixel).

Below are the key main variables available for reusing.

Datalayer Variable Field
ecommerce.purchase.actionField.revenue Transaction Revenue
ecommerce.purchase.actionField.id Transaction ID
ecommerce.currencyCode Currency Code
ecommerce.purchase.actionField.coupon Transaction Coupon
ecommerce.purchase.actionField.tax Tax Cost
ecommerce.purchase.actionField.shipping Shipping Cost

To show a simple demo of real use case,  will setup a Facebook pixel for Purchase event.  

To start with,  

1️⃣ create two VRAIBLES -  EEC Purchase - Revenue & EEC Purchase - Currency.

2️⃣ TAGS

Now configuring a standard Facebook pixel PURCHASE event, specifying currency and revenue from the datalayer.  

(assuming Facebook page view event wile be fired before this event)

3️⃣ TRIGGERS

Trigger will depend on your setup, if event is set within the EEC datalayer then specify that event for the trigger.

Done!

Read more