[{"data":1,"prerenderedAt":7},["ShallowReactive",2],{"docs-chats\u002Fmanagement\u002Ffolder-sources":3,"docs-tabs-chats\u002Fmanagement\u002Ffolder-sources":6},{"content":4,"lastmod":5},"## Sources of the \"All\" folder\n\n> **The method ships in the `im 26.1300.0` update and is not yet available on all Bitrix24 accounts.** If the update has not reached your Bitrix24 account yet, the API returns `422 METHOD_NOT_YET_AVAILABLE` — this means the method has not been released on the account yet, not that the integration is broken.\n\n`GET \u002Fv1\u002Fchats\u002Ffolders\u002F:folderId\u002Fsources`\n\nReturns the sources of the \"All\" folder and which of them are enabled. The \"All\" folder gathers chats from several messenger sections — sources: tasks, collabs, Open Channels and others. To change the set of enabled sources, use [`PUT \u002Fv1\u002Fchats\u002Ffolders\u002F:folderId\u002Fsources`](\u002Fdocs\u002Fchats\u002Fmanagement\u002Ffolder-sources-update).\n\nWorks only with the \"All\" folder: other folders have no sources. Not every Bitrix24 account shows the \"All\" folder: if it is not in the folder list, it is switched off on that account.\n\nThe call requires a write-capable key: the first `GET` may create system folders, save the set of sources in the \"All\" folder and carry over previously pinned chats. A read-only key gets `403 WRITE_BLOCKED_READONLY_KEY` before any Bitrix24 call.\n\n## Parameters\n\n| Parameter | Type | Required | Description |\n|----------|-----|:-----:|---------|\n| `folderId` (path) | number | yes | ID of the \"All\" folder — the `id` of the folder with `type: \"system\"` and `code: \"all\"` from [`GET \u002Fv1\u002Fchats\u002Ffolders`](\u002Fdocs\u002Fchats\u002Fdiscovery\u002Ffolders) |\n\nThere are no query parameters. Any query parameter is rejected with `400 INVALID_PARAMS`.\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fchats\u002Ffolders\u002F7\u002Fsources\" \\\n  -H \"X-Api-Key: YOUR_API_KEY\"\n```\n\n### curl — OAuth application\n\n```bash\ncurl \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fchats\u002Ffolders\u002F7\u002Fsources\" \\\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\u002Fchats\u002Ffolders\u002F7\u002Fsources', {\n  headers: { 'X-Api-Key': 'YOUR_API_KEY' },\n})\n\nconst { data } = await res.json()\nconst enabled = data.sources.filter((s) => s.enabled).map((s) => s.code)\nconsole.log('Enabled:', enabled)\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fchats\u002Ffolders\u002F7\u002Fsources', {\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\n  },\n})\n\nconst { data } = await res.json()\nconst enabled = data.sources.filter((s) => s.enabled).map((s) => s.code)\nconsole.log('Enabled:', enabled)\n```\n\n## Response fields\n\n| Field | Type | Description |\n|------|-----|---------|\n| `success` | boolean | Always `true` on success |\n| `data.sources` | array | Sources in the order the interface shows them |\n| `data.sources[].folderId` | number | ID of the source's system folder |\n| `data.sources[].code` | string | Code of the source — the value to pass in `sourceCodes` of [`PUT \u002Fv1\u002Fchats\u002Ffolders\u002F:folderId\u002Fsources`](\u002Fdocs\u002Fchats\u002Fmanagement\u002Ffolder-sources-update) |\n| `data.sources[].enabled` | boolean | The source is included in the \"All\" folder |\n| `data.sources[].togglable` | boolean | The source can be switched on and off. `false` for showcase sources: they are shown but cannot be switched on or off |\n| `data.folders` | array | The sources' system folders — the same fields as in [`GET \u002Fv1\u002Fchats\u002Ffolders`](\u002Fdocs\u002Fchats\u002Fdiscovery\u002Ffolders) |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"sources\": [\n      { \"folderId\": 2, \"code\": \"tasksTask\", \"enabled\": true, \"togglable\": true },\n      { \"folderId\": 4, \"code\": \"collab\", \"enabled\": false, \"togglable\": true },\n      { \"folderId\": 6, \"code\": \"openChannel\", \"enabled\": false, \"togglable\": false }\n    ],\n    \"folders\": [\n      {\n        \"id\": 2,\n        \"type\": \"system\",\n        \"code\": \"tasksTask\",\n        \"title\": \"Tasks\",\n        \"sort\": 3,\n        \"visible\": true,\n        \"description\": \"Task chats\",\n        \"displaysNestedInRoot\": false,\n        \"definition\": { \"recentSection\": \"tasksTask\", \"parentChatId\": 0 }\n      }\n    ]\n  }\n}\n```\n\n## Error response example\n\n422 — the folder is not \"All\":\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"BITRIX_ERROR\",\n    \"message\": \"This action is unavailable for this folder.\",\n    \"b24Code\": \"FOLDER_OPERATION_NOT_SUPPORTED\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|-----|---------|\n| 400 | `INVALID_PARAMS` | `folderId` is not a positive integer, or a query parameter was sent. Checked before any call to Bitrix24 |\n| 404 | `ENTITY_NOT_FOUND` | Bitrix24 answered \"not found\", the Bitrix24 code is in `error.b24Code` |\n| 422 | `METHOD_NOT_YET_AVAILABLE` | The `im 26.1300.0` update is not installed on the Bitrix24 account yet — see the notice at the top of the page |\n| 422 | `BITRIX_ERROR` | Bitrix24 returned an error, the Bitrix24 code is in `error.b24Code`: `FOLDER_OPERATION_NOT_SUPPORTED` — the folder has no sources or a concurrent write to the same folder is in progress. In the second case nothing is written, and the call can be retried. `FOLDER_NOT_FOUND` — no such folder, `FOLDER_ACCESS_DENIED` — another user's folder |\n| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 is unavailable or returned a server error |\n| 403 | `SCOPE_DENIED` | The API key does not have the `im` scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The key is read-only |\n| 401 | `TOKEN_MISSING` | The API key has no Bitrix24 tokens configured |\n\nFull list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\n- The mandatory source is not shown in `data.sources`: it cannot be switched off. Sources unavailable to the user are not shown either.\n\n## See also\n\n- [Set the sources of the \"All\" folder](\u002Fdocs\u002Fchats\u002Fmanagement\u002Ffolder-sources-update)\n- [Chat folders](\u002Fdocs\u002Fchats\u002Fdiscovery\u002Ffolders)\n- [Folder chats](\u002Fdocs\u002Fchats\u002Fdiscovery\u002Ffolder-recent)\n- [Platform errors](\u002Fdocs\u002Ferrors\u002Fplatform#method_not_yet_available-422)\n","2026-10-07",{},1794739539705]