Open Channels in Bitrix24: API for Lines and Connectors

If you are developing integrations for Bitrix24 using AI tools (Codex, Claude Code, Cursor), connect to the MCP server so that the assistant can utilize the official REST documentation.

This section describes two related areas of the API.

  • Open Channels — rules for processing inquiries within Bitrix24: operator queues, sessions, messages, chatbots, events, and CRM integration.
  • Connectors — connecting and maintaining external communication channels through which clients write to open channels.

Quick navigation: all methods and events

User documentation: Contact Center and Open Channels

How to Choose a Section

Scenario

What to Use

Set up a line, operator queues, and inquiry processing rules

Methods from the Open Channels section

Connect your own external communication channel to Bitrix24

Methods from the Open Channels Connectors section

Connect an external open channel from another Bitrix24 to the current account

Method imopenlines.network.join

Subscribe to message, dialog, and status events

Events from the Connectors Events and Open Channels Events sections

Both sets of methods are used for your own external channel: imconnector.* for registering and maintaining the connector, and imopenlines.* for configuring the line and processing dialogs. If you need to connect an external open channel from another Bitrix24 account without registering your own connector, use the method imopenlines.network.join.

Relationships of Open Channels and Connectors with Other Objects

Chat. The system processes inquiries as an open channel chat. Operations with messages, operators, and sessions are performed through the chat.

Session. Within the chat, the inquiry proceeds as a session. To start a session, read history, connect an operator, and manage modes, use the group of methods imopenlines.session.*.

Operator. The line distributes inquiries among operators from the queue. Queue configuration is done through imopenlines.config.*, while operator actions in an active dialog are handled through the group of methods imopenlines.operator.*. To transfer a dialog to an operator, use USER_ID, which can be obtained through the methods user.get and user.search.

External User. A client from the external channel is linked to the dialog through USER_CODE. This identifier allows the system to determine which chat and session the inquiry belongs to.

Message. The correspondence between the client and the operator is associated with the chat and session. To send messages and save quick replies, use the methods from the Messages section, and for reacting to message changes — the Events section.

Chatbot. The bot can send messages, transfer the dialog to an operator, and end the session using methods from the group imopenlines.bot.*.

CRM. Open channel dialogs can be linked to CRM objects. To retrieve CRM chats, use the group of methods imopenlines.crm.chat.*, and to create a lead based on the dialog outcome — the method imopenlines.crm.lead.create.

Universal Lists. Quick replies are associated with the identifier QUICK_ANSWERS_IBLOCK_ID. You can obtain it using the method imopenlines.config.get, and set it when creating or updating a line using the methods imopenlines.config.add and imopenlines.config.update.

Key Identifiers

Identifier

Description

How to Obtain

CHAT_ID

Identifier of the open channel chat. Needed for actions with dialogs, messages, operators, and chatbots

imopenlines.session.open, imopenlines.dialog.get

SESSION_ID

Identifier of the session within the chat. Needed for reading history and managing the inquiry processing flow

imopenlines.session.history.get

USER_CODE

External code of the user from the communication channel. Needed to uniquely link the external client with the chat and session in the line

Generated by the external channel, used in imopenlines.session.open

USER_ID

Identifier of the Bitrix24 user. Needed for routing the dialog between operators and operator actions

user.get, user.search

LINE/CONFIG_ID

Identifier of the open channel. In the methods imconnector.*, the parameter LINE is usually used, while in the methods imopenlines.config.*, CONFIG_ID is used. This identifier is needed to retrieve line data, modify settings, and link connector messages

imopenlines.config.get, imopenlines.config.list.get, imopenlines.config.update

CONNECTOR

Identifier of the connector. Needed for the methods imconnector.* to work with the correct connected connector

Set during registration in imconnector.register in the ID parameter, then passed, for example, in imconnector.activate and imconnector.send.messages

How to Get Started

Connect Your Own External Channel via Connector

  1. Register and activate the connector: imconnector.register, imconnector.activate
  2. Create an open channel and link it to the channel: imopenlines.config.add, imconnector.connector.data.set
  3. Check message sending and connector status: imconnector.send.messages, imconnector.status

Connect an External Open Channel from Another Bitrix24

  1. Connect the line using the method imopenlines.network.join
  2. Check dialog processing: imopenlines.session.open, imopenlines.operator.answer, imopenlines.crm.message.add

To automate, connect events: Open Channels Events, Connectors Events

Overview of Methods and Events

Scope: imopenlines

Who can perform methods: depending on the method and access permissions to open channels

Open Channels

Section

When to Use

Key Methods

Line Settings

Create a line, update settings, and retrieve parameters

imopenlines.config.add, imopenlines.config.update, imopenlines.config.get

All methods in the section

Dialogs and Sessions

Find a chat, start a session, read history, and manage modes

imopenlines.session.open, imopenlines.session.start, imopenlines.session.history.get

All methods in the section

Operators

Transfer and finish a dialog, distribute inquiries among operators

imopenlines.operator.answer, imopenlines.operator.transfer, imopenlines.operator.finish

All methods in the section

Messages

Send a message and save a quick reply

imopenlines.crm.message.add, imopenlines.message.quick.save

All methods in the section

CRM Chats

Find a CRM chat and add participants

imopenlines.crm.chat.get, imopenlines.crm.chat.user.add

All methods in the section

Chatbots

Automate the dialog using a chatbot

imopenlines.bot.session.message.send, imopenlines.bot.session.transfer

All methods in the section

Events: Open Channels Events

Open Channels Connectors

Section

When to Use

Key Methods

Registration and Connection

Register a channel and activate it in the account

imconnector.register, imconnector.activate, imconnector.connector.data.set

Message Exchange

Send, modify, and delete messages from the external channel

imconnector.send.messages, imconnector.update.messages, imconnector.delete.messages

Service Operations

Check the connector status, get a list, and disconnect channels

imconnector.status, imconnector.list, imconnector.unregister

All connector methods: Open Channels Connectors

Events: Connectors Events