A case for affiliate marketers: how to use Keitaro in HasOffers


In this guide, we will go through a Keitaro installation on a HasOffer platform as an affiliate and will set up a Postback for a website.

 About a HasOffers Platform

HasOffers is one of the oldest and well-known platforms. It can be easily recognized from its UI. As an example, we took adsmain.com which uses HasOffers.


Preparing a Landing Website

Our aim is to save a {subid} into a session and send a postback after an action when the website gets traffic from Keitaro.

1. Set a code of saving a {subid} parameter into a session on a page where you plan to transfer traffic to.

if (!headers_sent() && !session_id()) {
if (isset($_GET['subid'])) {
    $_SESSION['subid'] = $_GET['subid'];

2. After a user makes an action, e.g. signs up, we have to send a postback. The postback is sent via a call to Keitaro postback address with sending necessary parameters:

$url = 'http://POSTBACK_URL?cost=1&status=registratered&sub_id_1=game1&subid=' . urlencode($_SESSION['subid']);

Write your Postback URL, which you can get in Keitaro in the ” Maintenance > Postback URL” menu instead of the “POSTBACK_URL”.

“cost” и “sub_id_1” parameters are added as an example of additional information you can send to Keitaro. Later, you’ll be able to see all information in reports.

Pay special attention to “status” and “subid” parameters. Status transfers the identification of an action, e.g. lead, sale, rebill, rejected. In this case, we transferred “registration”, which is a “lead” for Keitaro.

Campaign Settings

A campaign should be set up with a HasOffer as a source and should have one stream leading to a landing.

1. Add your website as a landing on a “Landing Page” page. Fill in the name, URL, and Redirect as a loading method. Add “?subid={subid}” to an URL.

2. Add a new traffic source on a “Source” page. Choose the “Hasoffers.com” template.

3. Go to the “Campaigns” page, click “Create”.

4. Fill in the name, choose Hasoffers.com as a source, select CPA as a cost model.

5. Create a Stream, choose Landing Pages and Offers in a schema tab and add your landing page as an offer:

6. Copy the campaign’s link, we will need it a bit later.

Adding an offer on HasOffers

1. In a CPA network go to “Offers > Create offer”.

2. Fill in the following fields:

  • Name — the name of the offer.
  • Preview URL — your website address.
  • Default Offer URL — paste a tracking link we copied earlier on a Campaign page.
  • Conversion Tracking — choose “Server Postback w/Transaction ID”.


Next, you can add a conversion cost, targeting, and other parameters.

3. Go to the “Offers” page and click your offer.


4. Find the “CONVERSION POSTBACK URL” part and a”Postback URL” field. Pay attention to a domain and an offer_id — you will need them in step 6.


5. Open Keitaro > Sources, click your Hasoffers.com

6. Change a domain and an OFFER_ID in a “Postback URL” field. Leave only sending leads in statuses.


HasOffers gives you a link for testing, click it.


You should get to your website. On a website, perform an action that causes Postback in Keitaro, e.g. sign up, if you set up a postback on a registration.

You should see a just received postback from your website on a “Maintenance > Logs > Received Postbacks” page in Keitaro:


You should find an attempt to send a postback to a CPA network in a “Sent postbacks” tab:


The result is “Response: success=false; err_msg=Invalid Trans. ID #test1.;” because of a test link. You won’t find this in real traffic.

Useful articles:
Documentation about postbacks
Documentation about sent postbacks
Documentation about traffic sources

Keitaro Team

Team to deliver fresh and quality content!

View all posts by Keitaro Team →