# AmoCRM connection

Integration can accomplish three tasks:

- transmit messages from amoCRM channels;
- Provide data on transactions, contacts and companies;
- Manage the bot and automatic messages from the amoCRM interface.

## Before connecting n

Log in to amoCRM under an administrator or user with the right to install integrations. Determine which account and which funnels should ChatRex use.

## Installation of the widget

1. Open **Integrations** in ChatRex.
2. Press **Connect integration** and select **amoCRM**.
3. Open **Installation of connection**.
4. Press **Install widget**.
5. In the amoCRM window that opens, select the appropriate account and confirm permissions.
6. Return to ChatRex and check the status of **Connected**.

## Use as a channel

1. Open **My Bots → Change → Channels and Launch**.
2. Add amoCRM.
3. If necessary, set conditions for the funnel, stage and fields of the transaction, contact or company.
4. Set up a wait for the manager's response if the bot doesn't need to turn on right away.
5. Select the CRM data to be transmitted to the bot via `@` variables.
6. Save the changes.

If the bot needs to take into account previous correspondence, turn on the transmission of messages and set a reasonable amount of history.

## Management of the deal

Open the amoCRM deal and the **ChatRex** widget in the right panel. It shows the status of the bot. A working bot can be paused for 1 hour, 1 day or forever.

## Digital Pipeline Trigger

In the funnel settings, add the trigger **ChatRex** to the desired stage. For **Send a message**:

1. Choose a bot;
2. Select the amoCRM channel;
3. specify fixed text or enable generation through AI;
4. When generating, write an instruction and add the transaction fields via `@`;
5. Save the trigger.
6. Check it out on a test deal.

## Actions

To change the status and fields of entities or set tasks, configure [**Actions amoCRM**](<../../actions/integrations/amocrm.md>).

## Verification

Use the test deal. Send a message through the amoCRM channel, check the launch of the desired bot, transmitted fields and record in history. Then check each action separately.

!!!warning
The conditions of several bots in one funnel should not overlap. Otherwise, a single message can trigger multiple scenarios.
!!!
