How to link your affiliate link when creating a website with Tilda, LPgenerator, Flexbe and Wix
To use any builder, you need a link for setting up integration with Traffic Light first.

A link looks like this:
http://api.cpa.tl/api/lead/constructor/tilda?key=qwerty&offer_id=1234

Where:
qwerty = Traffic Light API key.
1234 = Traffic Light offer ID.
Tilda
1. Open the constructor and select the website you'd like to link. Open settings, go to forms and open Webhook.

2. Insert the link created for integration into the field below and press "Add" button:
3. Then, go to the landing page to order form, press the "Content" button and select Webhook in the "Data reception from forms" section.
4. Then, go to "Fields" section in the form settings.

For fields:
  • Name (variable name - name).
  • Phone number (variable name - phone). Make phone number field obligatory by ticking the corresponding box in settings.
  • Then, create a new country field that must look like a drop-down list (variable name - country). Countries should be set up depending on an offer. If you get a lead with an empty country field, it won't be processed, that's why you should set this field up as obligatory in Tilda form settings. The country field should provide data in the following format: [CODE] text* (for example, for Russia it will be: [RU] Russia).

Please make sure that name and phone are shown with a lowercase initial letter.

The process of integration with Tilda is over now. You can also specify other fields if you wish. You can find variable names here in "Lead receiver" section.
LPgenerator
For integration with Lpgenerator, you need:

● go to "Actions" tab in form settings of a landing page, find "Data transmission".

  • in the tab find the item "Sending data"
Insert your integration link into the link field.

http://api.cpa.tl/api/lead/constructor/lpgenerator?key=qwerty&offer_id=1234

Flexbe
For integration with Flexbe, you need:

● Go to website settings

● Select API in settings
● Insert a link to Webhook
The link is formed based on the template:
http://api.cpa.tl/api/lead/constructor/flexbe?key=ApiKey&offer_id=Offer_ID&country=strana


Where:
ApiKey – you can find your API key in your profile;
Offer_ID – the ID of the offer you're planning to drive traffic to,
strana – is to pass the info about GEO, which you can hide it. The format for passing GEO should look like that — RU (Russia) (similar for other GEOs). You can give this field any name, but it should be the name you came up with, not a standard generated one. This field must be filled in — it will replace a name with a value, for example: http://api.cpa.tl/api/lead/constructor/flexbe?key=eLnr6OqSzWnIRqTsu59JnedDchxhutfsUaEz0UZhc4&offer_id=2277&country=strana

Use standard Name and Phone number fields provided in the constructor. They are set up properly and given their "name" and "phone" names, that's why you don't have to specify them in the parameters.
Wix
For integration with Wix, you need:

● Select "Automated processes" in the main menu

  • Add a new automated process
● Setting an automated process: select "Wix forms" in "Trigger" section
● Then, enable Webhook in "Reaction" section
Insert a link based on the following template into "Target URL" field:
http://api.cpa.tl/api/lead/constructor/wix?key=KEY&offer_id=OFFER_ID&API_FIELD=FIELD_NAME

Parameters description:
  • KEY - your API key, you can find it on cpa.tl website
  • OFFER_ID – offer ID in our system
  • API_FIELD – the field that specifies a parameter, you can find names for all fields here in "Lead receiver" section.
  • FIELD_NAME – field name (see the next point to know where to find it)
  • If the fields for phone number and name are standard "phone number" and "name", you don't have to specify them in the parameters.

To find field name, you should:
  • Right click on the field on a page with a form.
  • Find "See code" in the menu.
  • You'll see page code editor where you can find the field name that can be specified in parameters (the name is in the element block id parameter).
  • In the parameters, specify the fields based on "Field_in_api = field on a page" principle, meaning that if you have a drop-down list "country" which you have to specify, you have to find the field name in the page code and specify it in the link in country parameter. A link will look like this: http://d.cpa.tl/api/lead/constructor/wix?key=UpPEfylTRXpbFhGZPAWE1ms&offer_id=94&country=comp-khotz2dk
  • Example form has standard name and phone number fields, that's why we don't specify them.
  • In the country field, the data should be provided in [CODE] text format (example: [RU] Russia ,[AR] Argentina)