Binom Cost Synchronizer

I’d like to present you Binom Cost Synchronizer.

Binom Cost Synchronizer is a python script that synchronizes costs in Binom using traffic sources APIs.

List of supported traffic sources:
– PropellerAds

How to set it up on your server?

There is an install script to make everything less complicated for non-technical users that have to be executed. I’m also leaving short guidelines for more technical people here.

For technical people:

  • You have to fetch and execute bash script that installs git, python and pipenv and set up cronjob that executes script daily, 10 minutes after midnight.
  • Script can be fetched by wget (it executes it after downloading):
  • wget -O – | bash
  • Script clones git repository in the home directory of the current user, into ~/binom-cost-synchronizer – that’s where are the source files are located
  • Disabling synchronizer can be achieved by executing crontab -e and removing binom-cost-synchronizer line out of that file.

For non-technical people:
Log in to your Hetzner panel and select your project.

Navigate to rescue:

Click on Reset Root Password:

Copy that password (CTRL + C)

Open up console window:

Type in root as a login:

As a password use the one that you just reset – paste it here

Paste this into the console:

  • wget -O – | bash

This console is not pasting everything correctly and text needs to be fixed in two places:

The first thing to fix is replacing the semicolon ; with a colon :
The second thing to fix is replacing backslash \ with pipe |

You end up with this:

Hit enter. You should see ASCII art dollar sign that says that installation has started.

In the end, you will be asked a few questions about your:
Binom Domain – the domain that you are using to host your Binom WITH https:// at the start. Preferably just copy it from your browser:

Your domain is in the red rectangle part and that’s the thing that needs to be pasted.

Binom API Key – can be found in Binom settings, here:

You just need to paste a part that is in the red rectangle, without &api_key= prefix

PropellerAds API Key – can be found in PropellerAds settings

Create token and copy it:

Timezone – this is a number that represents UTC timezone that will be used when updating costs – for example, if you have your tracker set up on UTC+1 you have to input 1 there, for UTC-2 you have to input -2, etc.

That’s it. You should see a message that the installation finished. Your costs will be now updated daily based on PropellerAds API.

How does it work?

It executes python script daily, using cronjob on your server.

This python script is fetching your Binom Campaigns and matches it with traffic source campaigns based on the campaign URL.

Next, it fetches the cost of matched campaigns for the previous day using the configured timezone.

Lastly, it updates the cost of the Binom campaign(s) for the previous day using the configured timezone.

It supports using the same Binom campaign URL in multiple traffic source campaigns – cost is just adding itself up for the matched campaigns to the total cost of the given Binom campaign.


The script is solely based on the cronjob so removing it from that place disables it completely.

This can be achieved by running crontab -e command as user that installed it, removing a line that executes it, and saving changes.

All the source files are located in ~/binom-cost-synchronizer and can be removed afterward.


Since this is a far more delicate topic than Offer URL Generator and it requires API keys configuration for both Binom and Traffic Sources so I’m making source code public.

You can find the GitHub repository, with the README.MD that explains how to install it on your server over here:

So far only PropellerAds is supported but I’ve prepared a codebase in a way that is flexible to add new Traffic Sources later on if someone would need them.

Setting this up will require little techy knowledge of how to connect to your server using ssh and execute the install script, you can also follow up on Hetzner guidelines that I pointed out above.

There are two log files that are created in the script directory:
cron.log – saves outputs of the executed python script
update.log – logs which Binom campaign was updated and what is the new cost

I’ve been testing it since the last week and it is working as expected but I’m not running hundreds of campaigns so I was unable to test all possible cases in a larger campaign volume.

2 Replies to “Binom Cost Synchronizer”

  1. with the desired cost. This can be verified by computing the cost of the corresponding unweighted network We would like to thank three anonymous reviewers for their valuable inputs in improving this manuscript.

  2. Я неизменно благодарствую личных приятелей за то, собственно что они дали лично мне ссылочку на текущий сайтец

Leave a Reply

Your email address will not be published. Required fields are marked *