DataLayer for Google Tag Manager
How To Configure
Purchase Extension

Related Extensions

Get more from your Magento2 store!

Enhanced Success Page

Add cross-sell, upsell, related products, social media links and other elements to your order confirmation.

HTML Minifier for Magento2

Minification is the process of removing all unnecessary characters and spacing from your source code without changing its functionality.

Magento Enhanced E-commerce

If your are using Magento + Google Analytics, then you need Enhanced E-commerce for Google Tag Manager.

Integrate BounceX with Google Tag Manager

Purchase
Tag Configuration
  Tag type : Custom Html

Trigger Configuration
  Trigger: All Custom Events
  Event Name : purchase

HTML

<script>
require(['DataLayerPurchaseApi'], function (dataLayerPurchaseApi) {
    var purchase = dataLayerPurchaseApi();
    
    var bouncexFormat = {
        renameFieldTo: {id: 'sku', product_id: 'product_id' quantity: 'quantity', price: 'price'}
    }; 
    
    var bouncexItems = purchase.getItems(bouncexFormat);
    
    <!-- Start BounceX Conversion MultiPixel. Deploy at the beginning of document head. -->
    top.bouncex = top.bouncex || [];
    top.bouncex.push(["conversion", {
        "order_id": purchase.getOrder('order_id'),
        "email": purchase.getEmail(),
        "phone":"",
        "goal":"purchase",
        "transaction_origin": "website",
        "currency": purchase.getCurrencyCode(),
        "coupon": purchase.getOrder('coupon').split(','),
        "total_discount":purchase.getOrder('coupon'),
        "tax":purchase.getOrder('tax'),
        "shipping":purchase.getOrder('shipping'),
        "amount":purchase.getOrder('total'),
        "pay_method":purchase.getPaymetMethod('title'),
        "item":bouncexItems
    }]);
    <!-- End BounceX Conversion MultiPixel. -->
    
    var queryParms = {
        website_id: 'Add your Container Tag Id here',
        order_id: purchase.getOrder('order_id'),
        email: purchase.getEmail(),
        amount: purchase.getOrder('total'),
        goal: 'purchase'
    };
    
    purchase.setUrlDomain('//api.bounceexchange.com/capture/convert2.gif');
    purchase.addUrlParams(queryParms);
        
    var url = purchase.buildUrl();
    purchase.addImage(url);  
});
</script>
Related

Related Extensions

Get more from your Magento2 store!

Enhanced Transactional Emails

Get more from your order confirmation emails by promoting other complementary products.

Enhanced Success Page

Add cross-sell, upsell, related products, social media links and other elements to your order confirmation.

Order Shipment Tracking

Providing your customer with a beautiful and functional order package tracking without leaving your site.