Send Measurement Protocol data to your own collection endpoint

Updated on 2021-12-06

note:

This advanced connection is only available on Plus Plans

Overview

Littledata's Google Analytics connection for Shopify formats common e-commerce events into Google's Measurement Protocol standard. If you want to get this raw data pipeline directly to your own collection endpoint, you can add a URL within Littledata's settings.

You might want to use this data pipeline to:

Getting started

  1. Go to the Settings > Data pipeline tab in Littledata's app
  2. Under MPEndpoint Protocol enter a valid HTTPS endpoint. For example, https:/mycustomendpoint.mystore.com/collect
  3. Click SAVE to reapply the changes to our Shopify connection

How it works

Client side

Every event that our tracking script would normally relay to GA via gtag.js will be sent to your chosen endpoint. This is in addition to sending the hit to GA.

If you only want server-side events, you can disable this by removing the LittledataLayer.MPEndpoint value from our tracking script.

From the browser we send Pageviews and the following Enhanced Ecommerce events:

  • Product list views
  • Product list clicks
  • Product views
  • Product image clicks
  • Social shares of product

Server side

Every event that our servers would normally relay to GA will be sent to your chosen endpoint. This is in addition to sending the hit to GA.

The Enhanced Ecommerce events sent from our servers are:

  • Adds to cart
  • Remove from cart
  • Checkout steps
  • Orders (including recurring orders)
  • Refunds
  • Customer updates

HTTP POST request example

Your endpoint needs to receive GET requests with 'Content-Type' set to application/x-www-form-urlencoded, with standard Measurement Protocol parameters.