Getting started with Events (Sales Insights)

 

Foreword

This tagging documentation only applies to Tracker from version 5.18.0.

If you can’t see the “Sales Insights” menu entry in Explorer, please get in touch with us so we get this activated for you.

Before beginning implementation of the Sales Insights plugin, please make sure you have initialised the AT Internet JavaScript Tracker and selected the plugin from within the Tag Composer interface.

If you are using Prestashop, we propose a plugin to ease the implementation in our marketplace.

 

Tagging methods

The JavaScript Ecommerce plugin makes it possible to measure actions related to products, shopping carts, and orders.

The Tracker has methods to send overall data (set + dispatch).

The “set” method allows a functional breakdown of the marking. The properties are grouped by categories (products, cart, etc.).

Example

tag.ecommerce.displayProduct.products.set([{
    "id": "1", 
    "variant": "1",
    "$": "laptop_A56",
    "brand": "ACER",
    "discount": 1,
    "pricetaxincluded": 549,
    "pricetaxfree": 456.2,
    "currency": "EUR",
    "stock": 1,
    "category1": "Computers_and_Networking",
    "category2": "Computers",
    "category3": "Laptops"
}]);
 

Configuration

The plugin also makes it possible to activate an automated SalesTracker tagging based on the Ecommerce data entered. This option is enabled using the “autoSalesTracker” variable in the “Ecommerce” configuration object:

var config = {
    Ecommerce: {
        autoSalesTracker: true
    }
};
var tag = new ATInternet.Tracker.Tag(config);

If the “autoSalesTracker” option is forced to the “true” value and the corresponding Ecommerce tagging data has been added, the following SalesTracker tags are automatically activated:

  • the viewed products tag (data from the Ecommerce tag for product sheet)
  • the cart content tag (data from the Ecommerce tag for cart display)
  • the orders tag (data from the Sales Ecommerce tag for transaction confirmation)

If necessary, it is also possible to overload the Sales Ecommerce collection domain.

Example

var config = {
    Ecommerce: {
        collectDomain: "collect-euw1.ati-host.net"
    }
};
var tag = new ATInternet.Tracker.Tag(config);
 

Appendix: setup variables

NameDefault valueDescriptionVersion
Ecommerce.collectDomain“”Sales Insights collect domain >= 5.13.0
Ecommerce.autoSalesTrackerfalseEnable automatic SalesTracker order content measurement on a transaction confirmation event >= 5.13.0
 

Was this post helpful?

Last update: 13/08/2019