[{"data":1,"prerenderedAt":14},["ShallowReactive",2],{"docs-openlines\u002Foperator":3,"docs-tabs-openlines\u002Foperator":6},{"content":4,"lastmod":5},"# Operator actions and my pause\n\nActions on an Open Channel dialog on behalf of the employee the key belongs to: skip a dialog, transfer it, mark the client as spam, finish another operator's dialog. This section also covers reading, starting and stopping your own operator pause.\n\nBitrix24 API: `imopenlines.operator.*`\nScope: `imopenlines`\n\n## On whose behalf the action runs\n\nThese methods take no employee parameter. The action and the pause apply to the employee the call runs as:\n\n| Authorization | Employee |\n|---|---|\n| Personal key (`X-Api-Key: YOUR_API_KEY`) | The key owner |\n| OAuth application (`X-Api-Key: YOUR_APP_KEY` + `Authorization: Bearer USER_SESSION_TOKEN`) | The user whose session is passed in `Authorization` |\n\nPermissions for the action are checked against this employee. Every method except reading the pause requires a key with write access.\n\n## Chat ID\n\nThe methods take `chatId`, the numeric ID of the Open Channel chat, for example `5255`. It is not a `dialogId` such as `chat5255` and not a `sessionId`. One chat goes through several sessions, and the action applies to the chat's current session.\n\nWhere to get `chatId`:\n\n- The `chatId` field in the [`POST \u002Fv1\u002Fopenlines\u002Fsessions\u002Fsearch`](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch) response.\n- [`POST \u002Fv1\u002Fopenlines\u002Fsessions\u002Fopen`](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fopen) — by the client's code in the connector.\n- [`GET \u002Fv1\u002Fopenlines\u002Fcrm\u002Fchats`](\u002Fdocs\u002Fopenlines\u002Fcrm-chats) — by a CRM card.\n\n## Typical scenario\n\n1. Find the client's chat: [`POST \u002Fv1\u002Fopenlines\u002Fsessions\u002Fsearch`](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch) by channel, or [`POST \u002Fv1\u002Fopenlines\u002Fsessions\u002Fopen`](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fopen) by the client's code.\n2. Take the dialog yourself: [`POST \u002Fv1\u002Fopenlines\u002Fsessions\u002Fstart`](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fstart). The employee the call runs as becomes the session operator.\n3. Transfer the dialog to a colleague or to the channel queue: [`POST \u002Fv1\u002Fopenlines\u002Foperator\u002Ftransfer`](\u002Fdocs\u002Fopenlines\u002Foperator\u002Ftransfer).\n4. Finish a dialog that another operator is handling: [`POST \u002Fv1\u002Fopenlines\u002Foperator\u002Ffinish-another`](\u002Fdocs\u002Fopenlines\u002Foperator\u002Ffinish-another).\n\n## Operations\n\n- [Skip a dialog](.\u002Foperator\u002Fskip.md) — `POST \u002Fv1\u002Fopenlines\u002Foperator\u002Fskip`\n- [Mark the client as spam](.\u002Foperator\u002Fspam.md) — `POST \u002Fv1\u002Fopenlines\u002Foperator\u002Fspam`\n- [Transfer a dialog](.\u002Foperator\u002Ftransfer.md) — `POST \u002Fv1\u002Fopenlines\u002Foperator\u002Ftransfer`\n- [Finish another operator's dialog](.\u002Foperator\u002Ffinish-another.md) — `POST \u002Fv1\u002Fopenlines\u002Foperator\u002Ffinish-another`\n- [Read my pause](.\u002Foperator\u002Fpause.md) — `GET \u002Fv1\u002Fopenlines\u002Foperator\u002Fpause`\n- [Start my pause](.\u002Foperator\u002Fpause-start.md) — `POST \u002Fv1\u002Fopenlines\u002Foperator\u002Fpause`\n- [Stop my pause](.\u002Foperator\u002Fpause-stop.md) — `DELETE \u002Fv1\u002Fopenlines\u002Foperator\u002Fpause`\n\n## See also\n\n- [Open Channels](\u002Fdocs\u002Fopenlines)\n- [Session search](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch)\n- [Chats by CRM card](\u002Fdocs\u002Fopenlines\u002Fcrm-chats)\n- [Open Channel configurations](\u002Fdocs\u002Fopenlines\u002Fconfig)\n","2026-10-19",{"operator\u002Fskip.md":7,"operator\u002Fspam.md":8,"operator\u002Ftransfer.md":9,"operator\u002Ffinish-another.md":10,"operator\u002Fpause.md":11,"operator\u002Fpause-start.md":12,"operator\u002Fpause-stop.md":13},"## Skip a dialog\n\n`POST \u002Fv1\u002Fopenlines\u002Foperator\u002Fskip`\n\nDeclines an Open Channel dialog offered to the employee: the dialog returns to the channel queue.\n\nThe action runs on behalf of the employee the key belongs to — see [On whose behalf the action runs](\u002Fdocs\u002Fopenlines\u002Foperator#on-whose-behalf-the-action-runs).\n\n## Request fields (body)\n\n| Field | Type | Required | Description |\n|---|---|:---:|---|\n| `chatId` | number \\| string | yes | Open Channel chat identifier, a positive integer. A string is accepted if it consists of digits only and does not start with zero. See [Chat ID](\u002Fdocs\u002Fopenlines\u002Foperator#chat-id) |\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X POST https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fskip \\\n  -H \"X-Api-Key: YOUR_API_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\"chatId\": 5255}'\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X POST https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fskip \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\"chatId\": 5255}'\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fskip', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({ chatId: 5255 }),\n})\n\nconst body = await res.json()\nif (!body.success) throw new Error(`${body.error.code}: ${body.error.message}`)\nconsole.log('Dialog skipped:', body.data.chatId)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fskip', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({ chatId: 5255 }),\n})\n\nconst body = await res.json()\nif (!body.success) throw new Error(`${body.error.code}: ${body.error.message}`)\nconsole.log('Dialog skipped:', body.data.chatId)\n```\n\n## Response fields\n\n| Field | Type | Description |\n|---|---|---|\n| `success` | boolean | `true` |\n| `data.chatId` | number | Chat identifier from the request. A string from the request is returned as a number |\n| `data.skipped` | boolean | Always `true` |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"chatId\": 5255,\n    \"skipped\": true\n  }\n}\n```\n\n## Error response example\n\n404 — no chat with this identifier:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"ENTITY_NOT_FOUND\",\n    \"message\": \"Open Line chat not found\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|---|---|---|\n| 400 | `INVALID_CHAT_ID` | `chatId` is missing, is not a positive integer, is a string with non-digit characters or a leading zero, or is greater than 9007199254740991 |\n| 404 | `ENTITY_NOT_FOUND` | No chat with this `chatId` |\n| 422 | `BITRIX_ERROR` | The dialog has already been accepted by an operator — the employee the call runs as or another employee. `error.message` is `Bitrix24 API error: 400`, and there is no `error.b24Code` field. To hand an accepted dialog to a colleague or to the queue, use [`POST \u002Fv1\u002Fopenlines\u002Foperator\u002Ftransfer`](\u002Fdocs\u002Fopenlines\u002Foperator\u002Ftransfer) |\n| 422 | `BITRIX_ERROR` | The chat has no open session: the dialog is already finished. `error.b24Code` is `ACCESS_DENIED_KICK`, and `error.message` is in the portal language |\n| 403 | `BITRIX_ACCESS_DENIED` | The employee the call runs as has no permission for the action |\n| 502 | `OPENLINE_OPERATOR_FAILED` | Bitrix24 responded without an error but did not confirm the action |\n| 403 | `SCOPE_DENIED` | The key has no `imopenlines` scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The key is read-only |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |\n| 401 | `INVALID_API_KEY` | The key is not recognized |\n| 401 | `TOKEN_MISSING` | A personal key has no access to the Bitrix24 portal, or an application key was sent without a session token in `Authorization` |\n| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 is unavailable or the connection to it broke before the response was complete |\n\nFull list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## See also\n\n- [Operator actions and my pause](\u002Fdocs\u002Fopenlines\u002Foperator)\n- [Transfer a dialog](\u002Fdocs\u002Fopenlines\u002Foperator\u002Ftransfer)\n- [Session search](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch)\n- [Open Channels](\u002Fdocs\u002Fopenlines)\n","## Mark the client as spam\n\n`POST \u002Fv1\u002Fopenlines\u002Foperator\u002Fspam`\n\nMarks the Open Channel client as spam and closes the current session of their chat, finishing the dialog with them.\n\nThe action runs on behalf of the employee the key belongs to — see [On whose behalf the action runs](\u002Fdocs\u002Fopenlines\u002Foperator#on-whose-behalf-the-action-runs).\n\n## Request fields (body)\n\n| Field | Type | Required | Description |\n|---|---|:---:|---|\n| `chatId` | number \\| string | yes | Open Channel chat identifier, a positive integer. A string is accepted if it consists of digits only and does not start with zero. See [Chat ID](\u002Fdocs\u002Fopenlines\u002Foperator#chat-id) |\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X POST https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fspam \\\n  -H \"X-Api-Key: YOUR_API_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\"chatId\": 5253}'\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X POST https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fspam \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\"chatId\": 5253}'\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fspam', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({ chatId: 5253 }),\n})\n\nconst body = await res.json()\nif (!body.success) throw new Error(`${body.error.code}: ${body.error.message}`)\nconsole.log('Client marked as spam, chat:', body.data.chatId)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fspam', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({ chatId: 5253 }),\n})\n\nconst body = await res.json()\nif (!body.success) throw new Error(`${body.error.code}: ${body.error.message}`)\nconsole.log('Client marked as spam, chat:', body.data.chatId)\n```\n\n## Response fields\n\n| Field | Type | Description |\n|---|---|---|\n| `success` | boolean | `true` |\n| `data.chatId` | number | Chat identifier from the request. A string from the request is returned as a number |\n| `data.spammed` | boolean | Always `true` |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"chatId\": 5253,\n    \"spammed\": true\n  }\n}\n```\n\n## Error response example\n\n404 — no chat with this identifier:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"ENTITY_NOT_FOUND\",\n    \"message\": \"Open Line chat not found\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|---|---|---|\n| 400 | `INVALID_CHAT_ID` | `chatId` is missing, is not a positive integer, is a string with non-digit characters or a leading zero, or is greater than 9007199254740991 |\n| 404 | `ENTITY_NOT_FOUND` | No chat with this `chatId` |\n| 422 | `BITRIX_ERROR` | Bitrix24 refused the action. The refusal code, if Bitrix24 returned one, is in `error.b24Code` |\n| 403 | `BITRIX_ACCESS_DENIED` | The employee the call runs as has no permission for the action |\n| 502 | `OPENLINE_OPERATOR_FAILED` | Bitrix24 responded without an error but did not confirm the action |\n| 403 | `SCOPE_DENIED` | The key has no `imopenlines` scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The key is read-only |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |\n| 401 | `INVALID_API_KEY` | The key is not recognized |\n| 401 | `TOKEN_MISSING` | A personal key has no access to the Bitrix24 portal, or an application key was sent without a session token in `Authorization` |\n| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 is unavailable or the connection to it broke before the response was complete |\n\nFull list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\n- **The response does not prove there was an open dialog.** For a chat whose session is already closed, and on a repeated call, the method returns the same response with `spammed: true`, and no new session is created. To check whether the call closed a session, use [`POST \u002Fv1\u002Fopenlines\u002Fsessions\u002Fsearch`](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch): a session closed by this method has `status` and `closeReason` equal to `spam`.\n\n## See also\n\n- [Operator actions and my pause](\u002Fdocs\u002Fopenlines\u002Foperator)\n- [Finish another operator's dialog](\u002Fdocs\u002Fopenlines\u002Foperator\u002Ffinish-another)\n- [Session search](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch)\n- [Open Channels](\u002Fdocs\u002Fopenlines)\n","## Transfer a dialog\n\n`POST \u002Fv1\u002Fopenlines\u002Foperator\u002Ftransfer`\n\nTransfers the current session of an Open Channel chat to another employee or to the channel queue.\n\nThe action runs on behalf of the employee the key belongs to — see [On whose behalf the action runs](\u002Fdocs\u002Fopenlines\u002Foperator#on-whose-behalf-the-action-runs).\n\n## Request fields (body)\n\n| Field | Type | Required | Description |\n|------|-----|:-----:|----------|\n| `chatId` | number \\| string | yes | Open Channel chat identifier, a positive integer. A string is accepted if it consists of digits only and does not start with zero. See [Chat ID](\u002Fdocs\u002Fopenlines\u002Foperator#chat-id) |\n| `userId` | number \\| string | no | ID of the employee the dialog is transferred to. List: [`GET \u002Fv1\u002Fusers`](\u002Fdocs\u002Fentities\u002Fusers\u002Flist) |\n| `queueId` | number \\| string | no | ID of the channel whose queue receives the dialog. List: [`GET \u002Fv1\u002Fopenline-configs`](\u002Fdocs\u002Fopenlines\u002Fconfig\u002Flist) |\n| `transferId` | number \\| string | no | The target as a single value: a `queue\u003Cid>` string targets a channel queue, for example `queue59`. A number or a digit string targets an employee by ID |\n\nPass exactly one of `userId`, `queueId` and `transferId`.\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X POST https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Ftransfer \\\n  -H \"X-Api-Key: YOUR_API_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n    \"chatId\": 5255,\n    \"userId\": 1295\n  }'\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X POST https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Ftransfer \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n    \"chatId\": 5255,\n    \"userId\": 1295\n  }'\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Ftransfer', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({\n    chatId: 5255,\n    userId: 1295,\n  }),\n})\n\nconst { success, data, error } = await res.json()\nif (!success) throw new Error(`${error.code}: ${error.message}`)\nconsole.log('Transferred:', data.transferred)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Ftransfer', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({\n    chatId: 5255,\n    userId: 1295,\n  }),\n})\n\nconst { success, data } = await res.json()\n```\n\n## Response fields\n\n| Field | Type | Description |\n|------|-----|----------|\n| `success` | boolean | `true` on a successful transfer |\n| `data.chatId` | number | Chat identifier from the request. A string from the request is returned as a number |\n| `data.transferred` | boolean | Always `true` |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"chatId\": 5255,\n    \"transferred\": true\n  }\n}\n```\n\n## Error response example\n\n400 — more than one target passed:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"INVALID_PARAMS\",\n    \"message\": \"Pass exactly one target: userId, queueId or transferId\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|-----|----------|\n| 400 | `INVALID_CHAT_ID` | `chatId` is missing, is not a positive integer, is a string with non-digit characters or a leading zero, or is greater than 9007199254740991 |\n| 400 | `INVALID_PARAMS` | No target passed, more than one target passed, or the target value is neither a positive integer nor a `queue\u003Cid>` string |\n| 404 | `ENTITY_NOT_FOUND` | No chat with this `chatId` |\n| 422 | `BITRIX_ERROR` | Bitrix24 refused the transfer. Its code is returned in `error.b24Code`. `OPERATOR_WRONG` with the text `You can not redirect to this operator` is returned in two cases: the target is the employee the call runs as, or there is no chat with this `chatId` |\n| 403 | `BITRIX_ACCESS_DENIED` | The employee the call runs as has no permission for the action |\n| 502 | `OPENLINE_OPERATOR_FAILED` | Bitrix24 neither confirmed the transfer nor returned an error |\n| 403 | `SCOPE_DENIED` | The key has no `imopenlines` scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The key is read-only |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |\n| 401 | `INVALID_API_KEY` | The key is not recognized |\n| 401 | `TOKEN_MISSING` | A personal key has no access to the Bitrix24 portal, or an application key was sent without a session token in `Authorization` |\n| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 is unavailable or the connection to it broke before the response was complete |\n\nFull list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\n- **A transfer to an employee keeps the session.** The session identifier stays the same while its operator changes, and the `queueTransfers` counter in the [session list](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch) increases by one.\n- **A transfer to a queue opens a new session.** After a transfer by `queueId` or by a `transferId` of the form `queue\u003Cid>`, the chat continues in a new session with the status `new` and no operator. Find its identifier in the [session list](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch) by `chatId`.\n\n## See also\n\n- [Operator actions and my pause](\u002Fdocs\u002Fopenlines\u002Foperator)\n- [Reassignment history](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Ftransfers)\n- [Session search](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch)\n- [Open Channel configurations](\u002Fdocs\u002Fopenlines\u002Fconfig)\n","## Finish another operator's dialog\n\n`POST \u002Fv1\u002Fopenlines\u002Foperator\u002Ffinish-another`\n\nFinishes an Open Channel dialog handled by another operator: the current session of the chat is closed.\n\nThe action runs on behalf of the employee the key belongs to — see [On whose behalf the action runs](\u002Fdocs\u002Fopenlines\u002Foperator#on-whose-behalf-the-action-runs).\n\n## Request fields (body)\n\n| Field | Type | Required | Description |\n|---|---|:---:|---|\n| `chatId` | number \\| string | yes | Open Channel chat identifier, a positive integer. A string is accepted if it consists of digits only and does not start with zero. See [Chat ID](\u002Fdocs\u002Fopenlines\u002Foperator#chat-id) |\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X POST https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Ffinish-another \\\n  -H \"X-Api-Key: YOUR_API_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\"chatId\": 5255}'\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X POST https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Ffinish-another \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\"chatId\": 5255}'\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Ffinish-another', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({ chatId: 5255 }),\n})\n\nconst body = await res.json()\nif (!body.success) throw new Error(`${body.error.code}: ${body.error.message}`)\nconsole.log('Dialog finished:', body.data.chatId)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Ffinish-another', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n    'Content-Type': 'application\u002Fjson',\n  },\n  body: JSON.stringify({ chatId: 5255 }),\n})\n\nconst body = await res.json()\nif (!body.success) throw new Error(`${body.error.code}: ${body.error.message}`)\nconsole.log('Dialog finished:', body.data.chatId)\n```\n\n## Response fields\n\n| Field | Type | Description |\n|---|---|---|\n| `success` | boolean | `true` |\n| `data.chatId` | number | Chat identifier from the request. A string from the request is returned as a number |\n| `data.finished` | boolean | Always `true` |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"chatId\": 5255,\n    \"finished\": true\n  }\n}\n```\n\n## Error response example\n\n404 — no chat with this identifier:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"ENTITY_NOT_FOUND\",\n    \"message\": \"Open Line chat not found\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|---|---|---|\n| 400 | `INVALID_CHAT_ID` | `chatId` is missing, is not a positive integer, is a string with non-digit characters or a leading zero, or is greater than 9007199254740991 |\n| 404 | `ENTITY_NOT_FOUND` | No chat with this `chatId` |\n| 422 | `BITRIX_ERROR` | The chat has no open session: the dialog is already finished. `error.b24Code` is `NOT_LOAD_SESSION_OR_CHAT`, and `error.message` is `Session or chat failed to load` |\n| 422 | `BITRIX_ERROR` | Bitrix24 refused the action for another reason. The refusal code, if Bitrix24 returned one, is in `error.b24Code` |\n| 403 | `BITRIX_ACCESS_DENIED` | The employee the call runs as has no permission for the action |\n| 502 | `OPENLINE_OPERATOR_FAILED` | Bitrix24 responded without an error but did not confirm the action |\n| 403 | `SCOPE_DENIED` | The key has no `imopenlines` scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The key is read-only |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |\n| 401 | `INVALID_API_KEY` | The key is not recognized |\n| 401 | `TOKEN_MISSING` | A personal key has no access to the Bitrix24 portal, or an application key was sent without a session token in `Authorization` |\n| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 is unavailable or the connection to it broke before the response was complete |\n\nFull list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\n- **The session is closed with `closeReason` equal to `operator`.** You can see it in [`POST \u002Fv1\u002Fopenlines\u002Fsessions\u002Fsearch`](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch). An operator finishes their own dialog with `POST \u002Fv1\u002Fopenlines\u002Foperator\u002Ffinish`, described in [Operator actions on a dialog](\u002Fdocs\u002Fopenlines\u002Fconfig#operator-actions-on-a-dialog).\n- **A repeated call right after finishing also returns `200`.** A repeated call within the first seconds after a successful finish returns `finished: true`, although the session is already closed. A minute later, a repeated call returns `422 BITRIX_ERROR` with `NOT_LOAD_SESSION_OR_CHAT`. To check whether the session is closed, use `status` in [`POST \u002Fv1\u002Fopenlines\u002Fsessions\u002Fsearch`](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch), not the response of a repeated call.\n\n## See also\n\n- [Operator actions and my pause](\u002Fdocs\u002Fopenlines\u002Foperator)\n- [Transfer a dialog](\u002Fdocs\u002Fopenlines\u002Foperator\u002Ftransfer)\n- [Mark the client as spam](\u002Fdocs\u002Fopenlines\u002Foperator\u002Fspam)\n- [Session search](\u002Fdocs\u002Fopenlines\u002Fsessions\u002Fsearch)\n- [Open Channels](\u002Fdocs\u002Fopenlines)\n","## Read my pause\n\n`GET \u002Fv1\u002Fopenlines\u002Foperator\u002Fpause`\n\nReturns the Open Channel operator pause state for the employee the call runs as.\n\nNo parameters. The employee is determined by authorization — see [On whose behalf the action runs](\u002Fdocs\u002Fopenlines\u002Foperator#on-whose-behalf-the-action-runs).\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X GET https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause \\\n  -H \"X-Api-Key: YOUR_API_KEY\"\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X GET https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\"\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause', {\n  headers: { 'X-Api-Key': 'YOUR_API_KEY' },\n})\nconst { data } = await res.json()\nconsole.log('Pause on:', data.paused)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause', {\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n  },\n})\nconst { data } = await res.json()\nconsole.log('Pause on:', data.paused)\n```\n\n## Response fields\n\n| Field | Type | Description |\n|------|-----|----------|\n| `success` | boolean | `true` on a successful request |\n| `data.paused` | boolean | `true` — the pause is on, `false` — it is off |\n\n## Response example\n\nThe pause is off:\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"paused\": false\n  }\n}\n```\n\n## Error response example\n\n401 — the `X-Api-Key` header is missing:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"MISSING_API_KEY\",\n    \"message\": \"API key required. Pass via X-Api-Key header.\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|-----|----------|\n| 422 | `BITRIX_ERROR` | Bitrix24 rejected the request. The refusal text is in `message` |\n| 403 | `BITRIX_ACCESS_DENIED` | The employee the call runs as has no permission for the action |\n| 502 | `OPENLINE_OPERATOR_FAILED` | Bitrix24 returned a non-boolean value instead of the pause state |\n| 403 | `SCOPE_DENIED` | The key has no `imopenlines` scope |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |\n| 401 | `INVALID_API_KEY` | The key is not recognized |\n| 401 | `TOKEN_MISSING` | A personal key has no access to the Bitrix24 portal, or an application key was sent without a session token in `Authorization` |\n| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 is unavailable or the connection to it broke before the response was complete |\n\nFull list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## See also\n\n- [Start my pause](\u002Fdocs\u002Fopenlines\u002Foperator\u002Fpause-start)\n- [Stop my pause](\u002Fdocs\u002Fopenlines\u002Foperator\u002Fpause-stop)\n- [Operator actions and my pause](\u002Fdocs\u002Fopenlines\u002Foperator)\n- [Open Channels](\u002Fdocs\u002Fopenlines)\n","## Start my pause\n\n`POST \u002Fv1\u002Fopenlines\u002Foperator\u002Fpause`\n\nTurns on the Open Channel operator pause for the employee the call runs as.\n\nNo parameters, no request body. The employee is determined by authorization — see [On whose behalf the action runs](\u002Fdocs\u002Fopenlines\u002Foperator#on-whose-behalf-the-action-runs).\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X POST https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause \\\n  -H \"X-Api-Key: YOUR_API_KEY\"\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X POST https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\"\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause', {\n  method: 'POST',\n  headers: { 'X-Api-Key': 'YOUR_API_KEY' },\n})\nconst { data } = await res.json()\nconsole.log('Pause on:', data.paused)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause', {\n  method: 'POST',\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n  },\n})\nconst { data } = await res.json()\nconsole.log('Pause on:', data.paused)\n```\n\n## Response fields\n\n| Field | Type | Description |\n|------|-----|----------|\n| `success` | boolean | `true` when the pause is turned on |\n| `data.paused` | boolean | Pause state re-read after the call. `true` in a successful response |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"paused\": true\n  }\n}\n```\n\n## Error response example\n\n401 — the `X-Api-Key` header is missing:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"MISSING_API_KEY\",\n    \"message\": \"API key required. Pass via X-Api-Key header.\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|-----|----------|\n| 422 | `BITRIX_ERROR` | Bitrix24 rejected the request. The refusal text is in `message` |\n| 403 | `BITRIX_ACCESS_DENIED` | The employee the call runs as has no permission for the action |\n| 502 | `OPENLINE_OPERATOR_FAILED` | The pause stayed off after the call: the re-read state is `false` |\n| 502 | `OPENLINE_OPERATOR_FAILED` | Bitrix24 returned a non-boolean value instead of the pause state |\n| 403 | `SCOPE_DENIED` | The key has no `imopenlines` scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The key is read-only |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |\n| 401 | `INVALID_API_KEY` | The key is not recognized |\n| 401 | `TOKEN_MISSING` | A personal key has no access to the Bitrix24 portal, or an application key was sent without a session token in `Authorization` |\n| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 is unavailable or the connection to it broke before the response was complete |\n\nFull list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\n- **Turning the pause on again does not return an error.** If the pause is already on, the call returns `200` with `paused: true`, and the state does not change.\n\n## See also\n\n- [Read my pause](\u002Fdocs\u002Fopenlines\u002Foperator\u002Fpause)\n- [Stop my pause](\u002Fdocs\u002Fopenlines\u002Foperator\u002Fpause-stop)\n- [Operator actions and my pause](\u002Fdocs\u002Fopenlines\u002Foperator)\n- [Open Channels](\u002Fdocs\u002Fopenlines)\n","## Stop my pause\n\n`DELETE \u002Fv1\u002Fopenlines\u002Foperator\u002Fpause`\n\nTurns off the Open Channel operator pause for the employee the call runs as.\n\nNo parameters, no request body. The employee is determined by authorization — see [On whose behalf the action runs](\u002Fdocs\u002Fopenlines\u002Foperator#on-whose-behalf-the-action-runs).\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X DELETE https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause \\\n  -H \"X-Api-Key: YOUR_API_KEY\"\n```\n\n### curl — OAuth application\n\n```bash\ncurl -X DELETE https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause \\\n  -H \"X-Api-Key: YOUR_APP_KEY\" \\\n  -H \"Authorization: Bearer USER_SESSION_TOKEN\"\n```\n\n### JavaScript — personal key\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause', {\n  method: 'DELETE',\n  headers: { 'X-Api-Key': 'YOUR_API_KEY' },\n})\nconst { data } = await res.json()\nconsole.log('Pause on:', data.paused)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fopenlines\u002Foperator\u002Fpause', {\n  method: 'DELETE',\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n  },\n})\nconst { data } = await res.json()\nconsole.log('Pause on:', data.paused)\n```\n\n## Response fields\n\n| Field | Type | Description |\n|------|-----|----------|\n| `success` | boolean | `true` when the pause is turned off |\n| `data.paused` | boolean | Pause state re-read after the call. `false` in a successful response |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"paused\": false\n  }\n}\n```\n\n## Error response example\n\n401 — the `X-Api-Key` header is missing:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"MISSING_API_KEY\",\n    \"message\": \"API key required. Pass via X-Api-Key header.\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|-----|----------|\n| 422 | `BITRIX_ERROR` | Bitrix24 rejected the request. The refusal text is in `message` |\n| 403 | `BITRIX_ACCESS_DENIED` | The employee the call runs as has no permission for the action |\n| 502 | `OPENLINE_OPERATOR_FAILED` | The pause stayed on after the call: the re-read state is `true` |\n| 502 | `OPENLINE_OPERATOR_FAILED` | Bitrix24 returned a non-boolean value instead of the pause state |\n| 403 | `SCOPE_DENIED` | The key has no `imopenlines` scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The key is read-only |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |\n| 401 | `INVALID_API_KEY` | The key is not recognized |\n| 401 | `TOKEN_MISSING` | A personal key has no access to the Bitrix24 portal, or an application key was sent without a session token in `Authorization` |\n| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 is unavailable or the connection to it broke before the response was complete |\n\nFull list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\n- **Turning the pause off again does not return an error.** If the pause is already off, the call returns `200` with `paused: false`, and the state does not change.\n\n## See also\n\n- [Read my pause](\u002Fdocs\u002Fopenlines\u002Foperator\u002Fpause)\n- [Start my pause](\u002Fdocs\u002Fopenlines\u002Foperator\u002Fpause-start)\n- [Operator actions and my pause](\u002Fdocs\u002Fopenlines\u002Foperator)\n- [Open Channels](\u002Fdocs\u002Fopenlines)\n",1795000564339]