amp-analytics to track Facebook Pixel lead events

460 Views Asked by At

I am trying to implement form lead conversions using amp-analytics and facebook pixel.

I found examples on using amp-analtics with facebook pixel here;

Github Amp Analytics Vendors

However, this does not go into any detail on how the events are built up? Currently I have the following amp code;

<amp-analytics type="facebookpixel" id="facebook-pixel">
    <script type="application/json">
        {
        "vars": {
        "pixelId": "MYPIXELID"
        },
        "triggers": {
        "trackPageview": {
        "on": "visible",
        "request": "pageview"
        },
        "trackEvent": {
        "on": "amp-form-submit-success",
        "selector": "#instantQuoteForm",
        "request": "event",
        "vars": {
        "value": "1.00",
        "currency": "£"
        }
        }
        }
        }
    </script>
</amp-analytics>

So currently I want to track pageviews and form submissions completed through this page. Currently I have this generated through the facebook events manager interface;

facebook screenshot ad manager

Can anyone direct me to any kind of documentation for this?

Update

To update the event tracking seems to be coming through to the facebook manager console. Per the image below;

event tracking page screenshot showing events

0

There are 0 best solutions below