Skip to main content

Lead Sending API – Method 2 (Example)

Support avatar
Written by Support
Updated over 3 years ago

This method is suitable for you if you are using traffic from Google or Facebook. As a result, you get a ready-made file with a record of all the leads on your hosting. To get permission to send a lead using this method, contact the support chat and wait for approval.

Set up a landing page using the example of the Reduslim offer.

  1. All landing pages from the affiliate program are available for download in the “Promo” section of the offer card.

image20.png

2. Go to the folder “Landings/Pre-landings“. Download files “privacy.html”, “report.html”.

image17.png

3. Check the landing path “reduslim24.com/ro/159/v1/index.htm”. As we can see, the landing is located in the “ro” folder. Download from the “ro” folder folders “confirm” and “confirm.html”.

image31.png

4. Go to the folder “159”. Here, download the folder “v1” and file “price.js”.

image65.png

5. Download the file for sending leads to php by following the link: download. Unzip all archives and group all downloaded files into one folder.

image41.png

6. Set up the lead sending file “lucky.php”. Open it in the text editor, change the token and hash to your api. Save the file.

image72.png

7. Find your API token in the LuckyOnline personal account.

image73.png

8. Campaign_hash - get hash when forming a flow.

image1.png

9. Change the “index.html" file extension to “index.php”. Open this file in a text editor, move over to the end of the file.

- delete the line from leadprofit.js + script with a hash.

image46.png

10. Delete all dots and slant characters (./ or ../../ or / ) before the following words:

- price.js - responsible for prices.

image30.png

- privacy.html, report.html - privacy policy.

image9.png

11. Search with “<form” to find every line, add the following data for every order form:

  • action="lucky.php"

  • method="POST"

An example:

image11.png

12. Set up “subid” and “utm tags” retrieval. If tags are used in the address bar, then when sending the lead, these tags will be filled in the statistics of the partner program.

Write the following lines into the form (using “<form”) after the line containing name="phone" in all the forms where we wrote “lucky.php ”:

<input type='hidden' name='utm_source' value='<?=$_GET['utm_source']?>' />

<input type='hidden' name='utm_content' value='<?=$_GET['utm_content']?>' />

<input type='hidden' name='utm_campaign' value='<?=$_GET['utm_campaign']?>' />

<input type='hidden' name='utm_term' value='<?=$_GET['utm_term']?>' />

<input type='hidden' name='utm_medium' value='<?=$_GET['utm_medium']?>' />

<input type='hidden' name='subid' value='<?=$_GET['subid']?>' />

<input type='hidden' name='subid1' value='<?=$_GET['subid1']?>' />

<input type='hidden' name='subid2' value='<?=$_GET['subid2']?>' />

<input type='hidden' name='subid3' value='<?=$_GET['subid3']?>' />

An example:

image14.png

13. The Facebook pixel or pixel of any other metric is written to the file “confirm.html " in <head>.

14. Make test orders from all forms of sending the lead to a valid phone number, adding to the link: ?subid1=1&subid2=2&subid3=3&utm_source=u&utm_content=c&utm_campaign=cam&utm_medium=m to check the correctness of lead sending setup.

15. We check if the lead has entered the partner program detalisation with all tags.

16. If an error occurs when sending the lead, then open the file “log.txt ” on your hosting and check the error. File “log.txt " records all successful and unsuccessful attempts to send leads from your landing page.

Did this answer your question?