Extension Code: Pinterest integration steps
Go to the app > More > Integrations: Extension Code
Click and view "Extension Code developer guides and samples"
Check disclaimer "I have read the App Extension developer guides and understand the risks of Extension code."
Click "Change"
5. Replace YOUR_TAG_ID, paste code, and click Save
// Pinterest base code: copy the latest codes from the ads platform
!function(e){if(!window.pintrk){window.pintrk=function()
{window.pintrk.queue.push(Array.prototype.slice.call(arguments))};var
n=window.pintrk;n.queue=[],n.version="3.0";var
t=document.createElement("script");t.async=!0,t.src=e;var
r=document.getElementsByTagName("script")[0];r.parentNode.insertBefore(t,r)}}
("https://s.pinimg.com/ct/core.js");
// set your tag id here
pintrk('load','YOUR_TAG_ID');
// optional: track just landing to checkout page
itc.addEventHandler('InitiateCheckout', function(payload, additional) {
pintrk('page');
pintrk('track', 'checkout_landed',{
value: payload.value,
currency: payload.currency,
order_quantity: payload.num_items
});
});
// track purchase
itc.addEventHandler('Purchase', function(payload, additional) {
pintrk('track', 'checkout',{
value: additional.total,
currency: payload.currency,
order_quantity: payload.num_items,
order_id: additional.transaction_id
});
});
6. Verify by placing a test checkout using Funnel > Preview
---