To track affiliate sales on PayWhirl with Affiliatly - http://www.affiliatly.com - You need to load the Affiliatly tracking script immediately after customers checkout successfully and inject data from the transaction into their script.

You can do this easily with the PayWhirl Custom Tracking Scripts APP. In the app there is a CONVERSION section you can paste custom scripts and they will only be loaded AFTER successful payment are made. You can also inject data from the transaction into the scripts before they load (general notes in the link above).

EXAMPLE SCRIPT (unmodified from Affiliatly):

<script type="text/javascript" src="https://www.affiliatly.com/other_frameworks.js?affiliatly_code=[affiliatly_id]&id_order=[order_id]&order_price=[subtotal]&order_coupons=[coupon_code]"></script>


Next, you must replace the following in the script with actual values:

[affiliatly_id]
[order_id]
[subtota]
[coupon_code] (optional) 


EXAMPLE MODIFIED SCRIPT (minus your Affiliatly id, which you still need to add and is located in your Affiliatly account):

<script type="text/javascript" src="https://www.affiliatly.com/other_frameworks.js?affiliatly_code=[affiliatly_id]&id_order={{invoice.id}}&order_price={{invoice.amount_due}}&order_coupons={{invoice.promo_code}}"></script>


Finally, once you have added your Affiliatly id to the modified tracking script above, you just need to paste it into the PayWhirl Custom Tracking Scripts App in your account in the CONVERSION tab and save your settings.

This will load your tracking script after successful purchases on PayWhirl and send over the required information to Affiliatly. 

Please note in this example we passed in the grand total {{invoice.amount_due}} into the order price section of the script but you might need to pass in {{invoice.subtotal}} depending on your use case.

Please let us know if you have any questions.

Best,
Team PayWhirl

Did this answer your question?