Get Open Line by ID imopenlines.config.get

Scope: imopenlines

Who can execute the method: any user

The method imopenlines.config.get retrieves the settings of an open line by its ID.

Method Parameters

Required parameters are marked with *

Name
type

Description

CONFIG_ID*
integer

The ID of the open line.

You can obtain the ID of the open line when creating an open line or by using the method to get the list of open lines

WITH_QUEUE
char

Return operator queue data. Possible values:

  • Y — yes
  • N — no

SHOW_OFFLINE
char

Return offline operators in the queue. Possible values:

  • Y — yes
  • N — no

Code Examples

How to Use Examples in Documentation

curl -X POST \
          -H "Content-Type: application/json" \
          -H "Accept: application/json" \
          -d '{
            "CONFIG_ID": 15,
            "WITH_QUEUE": "Y",
            "SHOW_OFFLINE": "Y"
          }' \
          https://**put_your_bitrix24_address**/rest/**put_your_user_id_here**/**put_your_webhook_here**/imopenlines.config.get
        
curl -X POST \
          -H "Content-Type: application/json" \
          -H "Accept: application/json" \
          -d '{
            "CONFIG_ID": 15,
            "WITH_QUEUE": "Y",
            "SHOW_OFFLINE": "Y",
            "auth": "**put_access_token_here**"
          }' \
          https://**put_your_bitrix24_address**/rest/imopenlines.config.get
        
try
        {
            const response = await $b24.callMethod(
                'imopenlines.config.get',
                {
                    CONFIG_ID: 15,
                    WITH_QUEUE: 'Y',
                    SHOW_OFFLINE: 'Y'
                }
            );
        
            const result = response.getData().result;
            console.log(result);
        }
        catch (error)
        {
            console.error(error);
        }
        
try {
            $response = $b24Service
                ->core
                ->call(
                    'imopenlines.config.get',
                    [
                        'CONFIG_ID' => 15,
                        'WITH_QUEUE' => 'Y',
                        'SHOW_OFFLINE' => 'Y',
                    ]
                );
        
            $result = $response
                ->getResponseData()
                ->getResult();
        
            print_r($result);
        } catch (Throwable $e) {
            echo $e->getMessage();
        }
        
BX24.callMethod(
            'imopenlines.config.get',
            {
                CONFIG_ID: 15,
                WITH_QUEUE: 'Y',
                SHOW_OFFLINE: 'Y'
            },
            function(result)
            {
                if (result.error())
                {
                    console.error(result.error());
                }
                else
                {
                    console.log(result.data());
                }
            }
        );
        
require_once('crest.php');
        
        $result = CRest::call(
            'imopenlines.config.get',
            [
                'CONFIG_ID' => 15,
                'WITH_QUEUE' => 'Y',
                'SHOW_OFFLINE' => 'Y',
            ]
        );
        
        print_r($result);
        

Response Handling

HTTP Status: 200

{
            "result": {
                "ID": "22",
                "ACTIVE": "Y",
                "LINE_NAME": "Bitrix24 Documentation",
                "CRM": "N",
                "CRM_CREATE": "lead",
                "CRM_CREATE_SECOND": "0",
                "CRM_CREATE_THIRD": "Y",
                "CRM_FORWARD": "Y",
                "CRM_CHAT_TRACKER": "N",
                "CRM_TRANSFER_CHANGE": "Y",
                "CRM_SOURCE": "create",
                "QUEUE_TIME": "60",
                "NO_ANSWER_TIME": "60",
                "QUEUE_TYPE": "evenly",
                "CHECK_AVAILABLE": "Y",
                "WATCH_TYPING": "N",
                "WELCOME_BOT_ENABLE": "Y",
                "WELCOME_MESSAGE": "N",
                "WELCOME_MESSAGE_TEXT": "Welcome to the open line [b]«Bitrix24 Documentation»[/b][br]The first available operator will respond to you.",
                "VOTE_MESSAGE": "Y",
                "VOTE_TIME_LIMIT": "0",
                "VOTE_BEFORE_FINISH": "Y",
                "VOTE_CLOSING_DELAY": "Y",
                "VOTE_MESSAGE_1_TEXT": "Please rate the quality of service.",
                "VOTE_MESSAGE_1_LIKE": "Thank you for your feedback!",
                "VOTE_MESSAGE_1_DISLIKE": "We are sorry we couldn't assist you, we will strive to improve.",
                "VOTE_MESSAGE_2_TEXT": "Please rate the quality of service.\r\n\r\nSend: 1 - good, 0 - bad",
                "VOTE_MESSAGE_2_LIKE": "Thank you for your feedback!",
                "VOTE_MESSAGE_2_DISLIKE": "We are sorry we couldn't assist you, we will strive to improve.",
                "AGREEMENT_MESSAGE": "N",
                "AGREEMENT_ID": "0",
                "CATEGORY_ENABLE": "N",
                "CATEGORY_ID": "0",
                "WELCOME_BOT_JOIN": "always",
                "WELCOME_BOT_ID": "597",
                "WELCOME_BOT_TIME": "180",
                "WELCOME_BOT_LEFT": "close",
                "NO_ANSWER_RULE": "text",
                "NO_ANSWER_FORM_ID": "0",
                "NO_ANSWER_BOT_ID": "0",
                "NO_ANSWER_TEXT": "Unfortunately, we cannot respond to you at this moment, we will definitely get back to you.",
                "WORKTIME_ENABLE": "Y",
                "WORKTIME_FROM": "0",
                "WORKTIME_TO": "23.59",
                "WORKTIME_TIMEZONE": "Europe/Berlin",
                "WORKTIME_HOLIDAYS": [
                    ""
                ],
                "WORKTIME_DAYOFF": [
                    ""
                ],
                "WORKTIME_DAYOFF_RULE": "text",
                "WORKTIME_DAYOFF_FORM_ID": "0",
                "WORKTIME_DAYOFF_BOT_ID": "0",
                "WORKTIME_DAYOFF_TEXT": "Unfortunately, we cannot respond to you at this moment.[br][br]Please write your question and we will definitely get back to you during working hours.",
                "CLOSE_RULE": "text",
                "CLOSE_FORM_ID": "0",
                "CLOSE_BOT_ID": "0",
                "CLOSE_TEXT": "Thank you for reaching out to us, please rate the quality of service.",
                "FULL_CLOSE_TIME": "0",
                "AUTO_CLOSE_RULE": "none",
                "AUTO_CLOSE_FORM_ID": "0",
                "AUTO_CLOSE_BOT_ID": "0",
                "AUTO_CLOSE_TIME": "3600",
                "AUTO_CLOSE_TEXT": "",
                "AUTO_EXPIRE_TIME": "86400",
                "DATE_CREATE": {},
                "DATE_MODIFY": {},
                "MODIFY_USER_ID": "27",
                "TEMPORARY": "N",
                "XML_ID": null,
                "LANGUAGE_ID": "de",
                "QUICK_ANSWERS_IBLOCK_ID": "181",
                "SESSION_PRIORITY": "0",
                "TYPE_MAX_CHAT": "answered_new",
                "MAX_CHAT": "0",
                "OPERATOR_DATA": "profile",
                "DEFAULT_OPERATOR_DATA": [],
                "KPI_FIRST_ANSWER_TIME": "0",
                "KPI_FIRST_ANSWER_ALERT": "N",
                "KPI_FIRST_ANSWER_LIST": null,
                "KPI_FIRST_ANSWER_TEXT": "Employee #OPERATOR# exceeded the allowable response time to the client for the first message. Dialog №#DIALOG#.",
                "KPI_FURTHER_ANSWER_TIME": "0",
                "KPI_FURTHER_ANSWER_ALERT": "N",
                "KPI_FURTHER_ANSWER_LIST": null,
                "KPI_FURTHER_ANSWER_TEXT": "Employee #OPERATOR# exceeded the allowable response time to the client for the message. Dialog №#DIALOG#.",
                "KPI_CHECK_OPERATOR_ACTIVITY": "N",
                "SEND_NOTIFICATION_EMPTY_QUEUE": "N",
                "USE_WELCOME_FORM": "N",
                "WELCOME_FORM_ID": "111",
                "WELCOME_FORM_DELAY": "Y",
                "SEND_WELCOME_EACH_SESSION": "Y",
                "CONFIRM_CLOSE": "Y",
                "IGNORE_WELCOME_FORM_RESPONSIBLE": "N",
                "QUEUE": [
                    "27",
                    "103"
                ],
                "QUEUE_FULL": {
                    "27": {
                        "ID": "245",
                        "SORT": "0",
                        "USER_ID": "27",
                        "DEPARTMENT_ID": "0",
                        "USER_NAME": null,
                        "USER_WORK_POSITION": null,
                        "USER_AVATAR": null,
                        "USER_AVATAR_ID": "0"
                    },
                    "103": {
                        "ID": "251",
                        "SORT": "1",
                        "USER_ID": "103",
                        "DEPARTMENT_ID": "0",
                        "USER_NAME": null,
                        "USER_WORK_POSITION": null,
                        "USER_AVATAR": null,
                        "USER_AVATAR_ID": "0"
                    }
                },
                "QUEUE_USERS_FIELDS": {
                    "27": {
                        "USER_NAME": null,
                        "USER_WORK_POSITION": null,
                        "USER_AVATAR": null,
                        "USER_AVATAR_ID": "0"
                    },
                    "103": {
                        "USER_NAME": null,
                        "USER_WORK_POSITION": null,
                        "USER_AVATAR": null,
                        "USER_AVATAR_ID": "0"
                    }
                },
                "QUEUE_ONLINE": "Y"
            },
            "time": {
                "start": 1773663905,
                "finish": 1773663905.742784,
                "duration": 0.7427840232849121,
                "processing": 0,
                "date_start": "2026-03-16T15:25:05+01:00",
                "date_finish": "2026-03-16T15:25:05+01:00",
                "operating_reset_at": 1773664505,
                "operating": 0
            }
        }
        

Returned Data

Name
type

Description

result
object

The result value. Possible values:

  • object — an object with open line settings (detailed description)
  • false — the line with the specified CONFIG_ID does not exist

time
time

Information about the request execution time

Object result

Name
type

Description

ID
string

The ID of the open line

LINE_NAME
string

The name of the open line

ACTIVE
string

The status of the line's activity. Possible values:

  • Y — the line is active
  • N — the line is inactive

CRM
string

The CRM operation status. Possible values:

  • Y — yes
  • N — no

CRM_CREATE
string

The scenario for creating a CRM entity

CRM_CREATE_SECOND
string

Additional mode for creating a CRM entity

CRM_CREATE_THIRD
string

Additional mode for creating a CRM entity. Possible values:

  • Y — yes
  • N — no

CRM_FORWARD
string

The status of forwarding to CRM. Possible values:

  • Y — yes
  • N — no

CRM_CHAT_TRACKER
string

The status of sending the dialog to the CRM tracker. Possible values:

  • Y — yes
  • N — no

CRM_TRANSFER_CHANGE
string

The status of changing the responsible person during transfer. Possible values:

  • Y — yes
  • N — no

CRM_SOURCE
string

The mode of working with the source in CRM

QUEUE_TYPE
string

The mode of distributing requests

QUEUE_TIME
string

The time for a request to move to the next operator

NO_ANSWER_TIME
string

The time until the no-answer scenario is triggered

CHECK_AVAILABLE
string

Check the availability of operators. Possible values:

  • Y — yes
  • N — no

WATCH_TYPING
string

Show the operator's typing. Possible values:

  • Y — yes
  • N — no

WELCOME_BOT_ENABLE
string

The status of using the welcome bot. Possible values:

  • Y — yes
  • N — no

WELCOME_MESSAGE
string

The status of the welcome message. Possible values:

  • Y — yes
  • N — no

WELCOME_MESSAGE_TEXT
string

The text of the welcome message

VOTE_MESSAGE
string

The status of the feedback request. Possible values:

  • Y — yes
  • N — no

VOTE_TIME_LIMIT
string

Time limit for feedback

VOTE_BEFORE_FINISH
string

Request feedback before the dialog ends. Possible values:

  • Y — yes
  • N — no

VOTE_CLOSING_DELAY
string

Use a delay for closing after feedback. Possible values:

  • Y — yes
  • N — no

VOTE_MESSAGE_1_TEXT
string

The text of the first feedback scenario

VOTE_MESSAGE_1_LIKE
string

The text for positive feedback in the first scenario

VOTE_MESSAGE_1_DISLIKE
string

The text for negative feedback in the first scenario

VOTE_MESSAGE_2_TEXT
string

The text of the second feedback scenario

VOTE_MESSAGE_2_LIKE
string

The text for positive feedback in the second scenario

VOTE_MESSAGE_2_DISLIKE
string

The text for negative feedback in the second scenario

AGREEMENT_MESSAGE
string

The status of displaying the agreement message. Possible values:

  • Y — yes
  • N — no

AGREEMENT_ID
string

The ID of the agreement

CATEGORY_ENABLE
string

The status of using categories. Possible values:

  • Y — yes
  • N — no

CATEGORY_ID
string

The ID of the category

WELCOME_BOT_JOIN
string

The mode of connecting the welcome bot

WELCOME_BOT_ID
string

The ID of the welcome bot

WELCOME_BOT_TIME
string

The waiting time for connecting the welcome bot

WELCOME_BOT_LEFT
string

The mode of disconnecting the welcome bot

NO_ANSWER_RULE
string

The scenario for no response from the operator

NO_ANSWER_FORM_ID
string

The ID of the no-answer scenario form

NO_ANSWER_BOT_ID
string

The ID of the no-answer scenario bot

NO_ANSWER_TEXT
string

The text of the no-answer message

WORKTIME_ENABLE
string

The status of considering working hours. Possible values:

  • Y — yes
  • N — no

WORKTIME_FROM
string

Start of working hours

WORKTIME_TO
string

End of working hours

WORKTIME_TIMEZONE
string

Time zone of working hours

WORKTIME_HOLIDAYS
array

Array of holidays

WORKTIME_DAYOFF
array

Array of days off

WORKTIME_DAYOFF_RULE
string

The scenario for handling requests during non-working hours

WORKTIME_DAYOFF_FORM_ID
string

The ID of the non-working hours scenario form

WORKTIME_DAYOFF_BOT_ID
string

The ID of the non-working hours scenario bot

WORKTIME_DAYOFF_TEXT
string

The text of the message during non-working hours

CLOSE_RULE
string

The scenario for closing the dialog

CLOSE_FORM_ID
string

The ID of the closing form

CLOSE_BOT_ID
string

The ID of the closing bot

CLOSE_TEXT
string

The text of the closing message

FULL_CLOSE_TIME
string

The time for full session closure

AUTO_CLOSE_RULE
string

The scenario for auto-closing

AUTO_CLOSE_FORM_ID
string

The ID of the auto-closing form

AUTO_CLOSE_BOT_ID
string

The ID of the auto-closing bot

AUTO_CLOSE_TIME
string

The time until auto-closing

AUTO_CLOSE_TEXT
string

The text for auto-closing

AUTO_EXPIRE_TIME
string

The time for activity expiration

DATE_CREATE
object

The creation date of the setting in serialized form

DATE_MODIFY
object

The modification date of the setting in serialized form

MODIFY_USER_ID
string

The ID of the user who modified the settings

TEMPORARY
string

The status of a temporary line. Possible values:

  • Y — temporary line
  • N — permanent line

XML_ID
string

External ID. Possible values:

  • string — external ID is set
  • null — external ID is not set

LANGUAGE_ID
string

The language of the line

QUICK_ANSWERS_IBLOCK_ID
string

The ID of the quick answers information block

SESSION_PRIORITY
string

The session priority

TYPE_MAX_CHAT
string

The mode for limiting active dialogs per operator

MAX_CHAT
string

Maximum active dialogs per operator

OPERATOR_DATA
string

The mode for displaying operator data

QUEUE
array

IDs of operators in the queue

QUEUE_FULL
object

Data of queue items. The key of the object is the user ID, the value is the queue (detailed description)

QUEUE_USERS_FIELDS
object

User fields in the queue. The key of the object is the user ID, the value is the user description (detailed description)

QUEUE_ONLINE
string

The status of checking the online status of operators. Possible values:

  • Y — yes
  • N — no

DEFAULT_OPERATOR_DATA
array

Set of default operator display fields

KPI_FIRST_ANSWER_TIME
string

Norm for the first response time

KPI_FIRST_ANSWER_ALERT
string

The status of notification for overdue first response. Possible values:

  • Y — yes
  • N — no

KPI_FIRST_ANSWER_LIST
array

List of recipients for first response notifications. Possible values:

  • array — list of recipients is set
  • null — list of recipients is not set

KPI_FIRST_ANSWER_TEXT
string

Text for overdue first response notification

KPI_FURTHER_ANSWER_TIME
string

Norm for subsequent response times

KPI_FURTHER_ANSWER_ALERT
string

The status of notification for overdue subsequent responses. Possible values:

  • Y — yes
  • N — no

KPI_FURTHER_ANSWER_LIST
array

List of recipients for subsequent response notifications. Possible values:

  • array — list of recipients is set
  • null — list of recipients is not set

KPI_FURTHER_ANSWER_TEXT
string

Text for overdue subsequent response notification

KPI_CHECK_OPERATOR_ACTIVITY
string

The status of monitoring operator activity. Possible values:

  • Y — yes
  • N — no

SEND_NOTIFICATION_EMPTY_QUEUE
string

The status of notifications for an empty queue. Possible values:

  • Y — yes
  • N — no

USE_WELCOME_FORM
string

The status of using the welcome form. Possible values:

  • Y — yes
  • N — no

WELCOME_FORM_ID
string

The ID of the welcome form

WELCOME_FORM_DELAY
string

The status of delay in showing the welcome form. Possible values:

  • Y — yes
  • N — no

SEND_WELCOME_EACH_SESSION
string

Show the welcome message in each session. Possible values:

  • Y — yes
  • N — no

CONFIRM_CLOSE
string

Require confirmation for closing. Possible values:

  • Y — yes
  • N — no

IGNORE_WELCOME_FORM_RESPONSIBLE
string

Ignore the responsible person in the welcome form. Possible values:

  • Y — yes
  • N — no

Object QUEUE_FULL

Name
type

Description

ID
string

The ID of the queue item record

SORT
string

Position in the queue

USER_ID
string

User ID

DEPARTMENT_ID
string

Department ID

USER_NAME
string

User name. Possible values:

  • string — user name is set
  • null — user name is not set

USER_WORK_POSITION
string

User position. Possible values:

  • string — position is set
  • null — position is not set

USER_AVATAR
string

Link to avatar. Possible values:

  • string — link to avatar is set
  • null — avatar is not set

USER_AVATAR_ID
string

Avatar file ID

Object QUEUE_USERS_FIELDS

Name
type

Description

USER_NAME
string

User name. Possible values:

  • string — user name is set
  • null — user name is not set

USER_WORK_POSITION
string

User position. Possible values:

  • string — position is set
  • null — position is not set

USER_AVATAR
string

Link to avatar. Possible values:

  • string — link to avatar is set
  • null — avatar is not set

USER_AVATAR_ID
string

Avatar file ID

Error Handling

HTTP Status: 400

{
            "error": "CONFIG_ID_EMPTY",
            "error_description": "Config ID can't be empty"
        }
        

Name
type

Description

error
string

String error code. It may consist of digits, Latin letters, and underscores

error_description
error_description

Textual description of the error. The description is not intended to be shown to the end user in its raw form

Possible Error Codes

Status

Code

Description

Value

400

CONFIG_ID_EMPTY

Config ID can't be empty

The CONFIG_ID parameter is not provided or is incorrect

Statuses and System Error Codes

HTTP Status: 20x, 40x, 50x

The errors described below may occur when calling any method.

Status

Code
Error Message

Description

500

INTERNAL_SERVER_ERROR
Internal server error

An internal server error has occurred, please contact the server administrator or Bitrix24 technical support

500

ERROR_UNEXPECTED_ANSWER
Server returned an unexpected response

An internal server error has occurred, please contact the server administrator or Bitrix24 technical support

503

QUERY_LIMIT_EXCEEDED
Too many requests

The request intensity limit has been exceeded

405

ERROR_BATCH_METHOD_NOT_ALLOWED
Method is not allowed for batch usage

The current method is not allowed to be called using batch

400

ERROR_BATCH_LENGTH_EXCEEDED
Max batch length exceeded

The maximum length of parameters passed to the batch method has been exceeded

401

NO_AUTH_FOUND
Wrong authorization data

Invalid access token or webhook code

400

INVALID_REQUEST
Https required

The methods must be called using the HTTPS protocol

503

OVERLOAD_LIMIT
REST API is blocked due to overload

The REST API is blocked due to overload. This is a manual individual block, to remove it you need to contact Bitrix24 technical support

403

ACCESS_DENIED
REST API is available only on commercial plans

The REST API is available only on commercial plans

403

INVALID_CREDENTIALS
Invalid request credentials

The user whose access token or webhook was used to call the method lacks permissions

404

ERROR_MANIFEST_IS_NOT_AVAILABLE
Manifest is not available

The manifest is not available

403

insufficient_scope
The request requires higher privileges than provided by the webhook token

The request requires higher privileges than those provided by the webhook token

401

expired_token
The access token provided has expired

The provided access token has expired

403

user_access_error
The user does not have access to the application

The user does not have access to the application. This means that the application is installed, but the account administrator has allowed access to this application only for specific users

500

PORTAL_DELETED
Portal was deleted

The public part of the site is closed. To open the public part of the site on an on-premise installation, disable the option "Temporary closure of the public part of the site". Path to the setting: Desktop > Settings > Product Settings > Module Settings > Main Module > Temporary closure of the public part of the site

Continue Learning