First, you will need to add the LeadDyno tracking code to every page your PayWhirl customers can potentially view in the system. This includes ALL widgets, the cart, and the various pages within your hosted customer portal.
To accomplish this, simply copy/paste your tracking code from your Lead Dyno account - https://app.leaddyno.com/tools into your PayWhirl account in the Custom Tracking Scripts App.
Your tracking code for every page should look like the one below but should have an actual value for "YOUR_PUBLIC_KEY" (ie. 364738362872873) from your Lead Dyno account.
<script type="text/javascript" src="https://static.leaddyno.com/js"></script>
<script>
LeadDyno.key = "YOUR_PUBLIC_KEY";
LeadDyno.recordVisit();
</script>
Next, you will need to include the following snippet of code in the PayWhirl Custom Scripts App in the CONVERSION section (loads after purchases only):
<script type="text/"javascript" src="https://static.leaddyno.com/js"></script>
<script>
LeadDyno.key = "YOUR_PUBLIC_KEY";
LeadDyno.recordPurchase('{{customer.email}}', {
purchase_code: '{{invoice.id}}',
purchase_amount: '{{invoice.amount_due}}'
}, function() {
console.log("Purchase successfully sent to LeadDyno");
});
</script>
This will inject your customer's email address, the invoice id, and the purchase total into your Lead Dyno script before it loads and is sent off to your account.
Note: You can also use the Lead Dyno javascript library if you would like to customize the integration further with specific lead information. http://developer.leaddyno.com/js-api.html For support with advanced implementations, please contact the Lead Dyno team through the appropriate channel.
Related Articles:
Please let us know if you have any questions.
Sincerely,
The PayWhirl Team