How to send leads via API?

An API is an application programming interface through which computer programs can communicate with each other. One application, for example, gets access to some data or functions of another.


Here are some simple examples:

- Possibility to register on the site using the data of social networks.

- Weather forecast applications on smartphones that receive data from the software of any weather services.

- Aggregator sites where you can choose the most profitable product or service.

- Ability to transfer analytics data.


We have already talked about the basic settings of the send leads via API in the video about Facebook pixel integration.

In this article, we will analyze the basic configuration steps and talk about another way. We also covered this issue in more detail in our video.



When creating a campaign, you need to choose a transfer method via API.

Next, you need to download the PHP version of the lander.

It already contains the API, but for the postback to work, you need to do a couple of manipulations.

Under the line “<form” - you need to write the inputs (we need the first one for the postback to work, in the second line we can specify additional parameters). For example, in teamwork, 2 webmasters drive traffic to the same offer - then they can indicate their names.


<input type="hidden" name="sub1" value="{subid}">

<input type="hidden" name="sub4" value="Name"/>


You can also add one more line with a different SAB to display other parameters, so that it would be more convenient to analyze statistics in the cabinet in the future.

Next, select this line:


'sub1' => (empty($_POST['sub1'])) ? $_GET['sub1'] : $_POST['sub1'],


And correct it to the format we need:


'sub1' => $_POST['sub1']

After that, we will have a configured transfer of postback and leads to the affiliate network.


Let's analyze another way to quickly and easily configure and what is needed for this:

  • Select the required landing page for work and place the order.php and success.php files in its folder.
  • In the Index.php file, you need to find and select the “ACTION” field (if it is not there, then you need to register it yourself, as in the example: action=”order.php”).

Next, in the file order.php - specify the webmaster token and in the next line indicate the stream id:

Save and you're done.

This method is the most simplified version and is suitable for landers from or other affiliate networks, or made by yourself. Each webmaster chooses the most suitable configuration method for himself, we always recommend testing different options to find the best one for yourself! With care for your profit,!



Want to start with nutra? Have questions about the case-study?

All the nutra is discussed now 24/7 in the telegram chat  Nutra Affiliate Community 

Quick help for beginners

Sweet cases for motivation

Exclusive bonuses from partners $$$$

Intelligent moderators and all support for affiliate network in one place