Page tree
Skip to end of metadata
Go to start of metadata


Integration of Roistat with AmoCRM works the following way: after the client makes an order, the new lead is created in AmoCRM automatically. Roistat transmits the visit number from the browser cookie roistat_visit to the additional field roistat of this lead.

(информация) If the value from the roistat field is accidentally deleted, Roistat will define the source of the visit while loading leads, so the deal will be transferred in the needed marketing channel. If a manager receives an order by telephone, he can ask the promo-code and enter it in the roistat field. 

(warning) Roistat cannot tag the amoCRM forms.

Sending the lead to CRM

If the lead is not marked as duplicate

  1. Roistat searches the client in CRM by phone number or email address.
  2. If the client is found, Roistat creates the deal and binds it to the client. If the client is not found, Roistat creates the new contact and new deal. 


Step 1. Add the additional field roistat 

  1. Log in to your amoCRM and open the Leads section.
  2. Click the New lead button in the upper right part of the window:

  3. Open the Setup tab:

  4. In the opened window, click the Add field button:

  5. Select the Text as the field type and enter the roistat in the Text field:

    (warning) The additional field should be named roistat, otherwise, the integration won't work.
  6. Click the Save button.  

(информация) Additional field ID is displayed in its settings:


(отметить) If you create a lead manually, you can fill in the roistat field with the data of the source of the lead. The information about the source of the lead will be displayed in Analytics. 

To bind the lead to the specified marketing channel, enter the following markers in the roistat field:

  • google{ID}, if you want to bind the deal to the Google Adwords channel. For example, google3.
  • merchant{ID}, if you want to bind the deal to the Google Merchant Center channel. For example, merchant4.
  • facebook{ID}, if you want to bind the deal to the Facebook channel. For example, facebook6.
  • seo_google, if you want to bind the deal to the SEO - Google channel.

Step 2. Configure the integration with amoCRM in the Rositat Integrations list

Connect the AmoCRM in the Integrations list

  1. Open the Integrations list.
  2. Select the amoCRM and click the Connect button. 

1. Configure the authorization settings

  1. Enter the URL-address of your amoCRM project in the Address field.
  2. Enter the e-mail address you use in amoCRM in the Login field.
  3. Enter your API key from amoCRM in the API key field. The API key can be found in your amoCRM profile:
  4. Click the Save button.

2. Distribute the statuses

Distribute the statuses of the deals by dragging them into the statuses groups:

3. Instruction of lead creation settings

Read the instructions of lead creation settings and click the Next button:

4. Configuring the advanced settings of loading the deals from CRM

Field for filtration: if you have several businesses in one CRM. you can select each business using the filtering field.

Filtration parameter: if the filtering field is empty, only the deals with empty fields will be loaded.

Revenue field: if this field is not chosen, the Revenue will be loaded from the standard CRM field.

First cost field: select the additional deal field for loading Cost. The profit will be calculated automatically.

Profit field: select the additional deal field for loading Profit. The value of this field will be used to automatically calculate the cost. 

Use the date of sale from the CRM: enable this mechanism if you want the date of the sale to be downloaded directly from the CRM.

5. Configure the sending of deals to CRM

Sending the deals to the Unsorted folder

(warning) Deals from the Unsorted folder are not loaded into Roistat.  

All leads are created as deals by default. If you want to create the leads as Unassembled, configure this mechanism step by step: 

  1. Enable the Send deals to the Unsorted option. 
  2. Connect the form in amoCRM. It is necessary due to the features of transmitting the leads from Roistat to CRM.  Enter the Form ID to the Form ID field in the amoCRM settings.

     How to get the Form ID in amoCRM
    1. Open the Leads section in amoCRM.
    2. Click the Setup button in the upper right corner of the page.
    3. Open the form settings.
    4. Go to the Form placement tab.
    5. Copy the Form ID from the code:

  3. Paste the Form ID into the Form identifier field.

  4. Paste the Form name into the Form name field.  

     How to find out the identifier of pipeline
    1. Open the Leads in your amoCRM project.
    2. Click the Settings button.
    3. Click the on Pipeline. Pipeline ID will be in the address bar:
    4. Enter the Pipeline ID into the Funnel identifier field.

 Assigning the tasks to the responsible managers

To make managers work with the incoming leads more effectively, enable the creation of tasks by new leads in CRM to the responsible manager:

(warning) This mechanism works only when leads are created as Leads in amoCRM. If the leads are sent to Unsorted, the tasks assignment does not work. 

To enable this mechanism, activate the switcher. Then, appoint the managers to the tasks.

6. Send deals to the CRM system: creating tasks

On this step, you can specify the Time for tasks completion, Task type, and Task text:

How to fill in the additional fields in amoCRM while creating the deal?

Additional fields can be filled in:

  • with the help of call-tracking;
  • with the help of email-tracking; 
  • with the help of lead hunter;
  • with the help of widgets;
  • with the help of website forms

In the table below you can see the name of the fields and their system names. 

These fields are supported by amoCRM by default:

Field name

Field ID 

Field description

Visitor ID


Unique visitor ID



The budget of the deal

Pipeline ID


Create a deal in the specific pipeline



Create a deal with the specific status in the specific pipeline



Create tags using a comma 



The ID of a responsible manager

User field

(warning) Roistat supports all types of user fields. 

However, if the client's field is a dropdown list, it is required to transmit not the value of the field, but the ID of the value in the dropdown list.

Field ID in amoCRMField that was created manually in amoCRM

How to find out the ID of the field in amoCRM

Open the lead in amoCRM and click the Setup button. Then, click on the field, and you will see the ID:

How amoCRM fields work with Roistat

Field typeHow it works
DATEReturns and accepts the values in the YYYY-MM-DD HH:MM:SS (year-month-day-hour-minute-second) format
SMART_ADDRESSTransmits the first value that was entered in the list

Step 3. Configure the automatic transfer of leads to CRM

We recommend configuring the transfer of deals to CRM via Roistat. In this case, the deal will be firstly sent to Roistat, and then Roistat will send them to CRM. To learn more about the advantages of this way of leads transfer, read this article

If you already configured the transfer of leads using the code, you shall fill in the additional field roistat with the value of cookie roistat_visit.

You can receive the value of this cookie using this code: 

$roistatVisitId = array_key_exists('roistat_visit', $_COOKIE) ? $_COOKIE['roistat_visit'] : "unknown";

Verifying the performance

  1. Create the lead on the website.
  2. Open the Integration list in your project. 
  3. Find the amoCRM integration and click the Configure button. 
  4. Click the Sent leads button and find the lead you created.
  5. Check if the visit number is specified in the Promo code field.  
  6. Find the successful status of the lead () is in the Sent field.
  7. Find the new lead with the visit number in your CRM.

(warning) Roistat can create leads in amoCRM only if you paid for amoCRM service or you have a trial account.

  • No labels