Conversion tracking might be vital in estimating and measuring the success of your ad campaigns. Here, we will explain how to set it up using Adserver.Online platform.

Adserver.Online supports server-to-server (s2s) conversion tracking as well as client-side (cookie-based) tracking. In most cases, these options are enough to track installs, registrations and other types of actions. Firstly, we will take a look at how to configure s2s tracking.

Server-to-server (s2s) conversion tracking

If you would like to set up a server-to-server conversion tracking, you need to do the following:

  • Firstly, you need to append an arbitrary parameter to your URL. For example: https://www.mywebsite.com/offer/?asoclick={click}
  • It will be changed to something like https://www.mywebsite.com/offer/?asoclick=112358 on redirect.
  • After that, you need to store that 112358 token and pass it back to our server by calling our API with https://api.adsrv.net/v2/conversion/create?token=112358 in case of conversion.

You can do it with PHP:

<?php file_get_contents('https://api.adsrv.net/v2/conversion/create?token=112358');

Or HTML on a thank you page:

<script>(new Image).src="https://api.adsrv.net/v2/conversion/create?token=112358";</script>

This way the conversion will be recorded. 

Moreover, you can send a custom amount in your URL. To do that, you need to append the "&amount=AMOUNT" parameter to the API URL above. Please note, the AMOUNT value overrides the CPA rate of the campaign and will be used in stats.

Cookie-based tracking

In order to implement client-side (cookie-based) conversion tracking, you need to follow these steps:

1. Firstly, you need to append _aso_clk={click} parameter to your Landing URL. The parameter name must be _aso_clk

2. Then place this piece of code on your landing page:

<script src="https://track.aso1.net/cnv.js"></script>

3. Finally, place the following code on your "Thank you" page:

<script src="https://track.aso1.net/cnv.js"></script>
<script>_ASO.Cnv.postback();</script>

Besides, you can send a custom amount. In order to do that, you need to set the amount you need as the second parameter of _ASO.Cnv.postback function. The first parameter has to be null.

<script>_ASO.Cnv.postback(null, AMOUNT);</script>

Cookie's lifetime is 2 weeks.

Please note, that cookies can be blocked some browsers/anti-ad plugins. In this case, conversions may not reach our server.

You can have a look at the example here.