[{"data":1,"prerenderedAt":7},["ShallowReactive",2],{"docs-entities\u002Fsites\u002Fmy-permissions":3,"docs-tabs-entities\u002Fsites\u002Fmy-permissions":6},{"content":4,"lastmod":5},"## My site permissions\n\n`GET \u002Fv1\u002Fsites\u002F:id\u002Fmy-permissions`\n\nReturns the operations the API key's user can perform on the site. Use it to check permissions before changing, publishing or deleting a site.\n\n## Parameters\n\n| Parameter | Type | Required | Description |\n|----------|-----|:-----:|---------|\n| `id` (path) | number | yes | Site identifier — a positive integer. List: [`GET \u002Fv1\u002Fsites`](\u002Fdocs\u002Fentities\u002Fsites\u002Flist) |\n| `scope` (query) | string | no | Internal landing scope: `KNOWLEDGE` \u002F `GROUP` \u002F `MAINPAGE`. Specify it if the site belongs to the corresponding scope. Otherwise `404 ENTITY_NOT_FOUND` is returned. An ordinary site requested with `scope` also returns `404` |\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fsites\u002F3\u002Fmy-permissions\" \\\n  -H \"X-Api-Key: YOUR_API_KEY\"\n```\n\n### curl — OAuth application\n\n```bash\ncurl \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fsites\u002F3\u002Fmy-permissions\" \\\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\u002Fsites\u002F3\u002Fmy-permissions', {\n  headers: {\n    'X-Api-Key': 'YOUR_API_KEY',\n  },\n})\n\nconst { success, data } = await res.json()\nconsole.log('Can publish:', data.operations.includes('public'))\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch('https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fsites\u002F3\u002Fmy-permissions', {\n  headers: {\n    'X-Api-Key': 'YOUR_APP_KEY',\n    'Authorization': 'Bearer USER_SESSION_TOKEN',\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 success |\n| `data.operations` | string[] | Operations of the key's user: `read` — view, `edit` — edit, `sett` — change settings, `public` — publish, `delete` — delete, `denied` — access denied. Can be an empty array |\n\n## Response example\n\nPermissions of a Bitrix24 account administrator:\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"operations\": [\n      \"denied\",\n      \"read\",\n      \"edit\",\n      \"sett\",\n      \"public\",\n      \"delete\"\n    ]\n  }\n}\n```\n\n## Error response example\n\n404 — site not found:\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"ENTITY_NOT_FOUND\",\n    \"message\": \"Site not found or not visible\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|------|-----|---------|\n| 400 | `INVALID_PARAMS` | `id` is not a positive integer |\n| 400 | `INVALID_SCOPE` | `scope` is not `KNOWLEDGE`, `GROUP` or `MAINPAGE` |\n| 404 | `ENTITY_NOT_FOUND` | No site with this `id`, the site is not accessible to the key's user, or it belongs to a different `scope` |\n| 409 | `LANDING_MODULE_NOT_ENABLED` | The Sites module is unavailable on this Bitrix24 account. Ask a Bitrix24 account administrator to enable it — until then a retry returns the same refusal |\n| 422 | `BITRIX_ERROR` | Bitrix24 returned the permissions in a form other than a list of strings, or rejected the request. The reason is in `message` |\n| 403 | `BITRIX_ACCESS_DENIED` | Bitrix24 denied access: the key's user is not an administrator, or the feature is unavailable on the Bitrix24 account |\n| 403 | `SCOPE_DENIED` | The API key does not have the `landing` scope |\n| 401 | `TOKEN_MISSING` | The API key has no configured tokens |\n| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |\n\nThe full list of common API errors — [Errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\n- **The method covers only the key's user.** Permissions of other employees and groups assigned via [`PUT \u002Fv1\u002Fsites\u002F:id\u002Fpermissions`](\u002Fdocs\u002Fentities\u002Fsites\u002Fpermissions) cannot be read with this method.\n- **`denied` in the list does not mean this user is blocked.** A Bitrix24 account administrator gets all six operations together with `denied`. Check for the operation you need — `edit`, `public`, `delete` — rather than for the absence of `denied`.\n\n## See also\n\n- [Site permissions](\u002Fdocs\u002Fentities\u002Fsites\u002Fpermissions)\n- [Reset site permissions](\u002Fdocs\u002Fentities\u002Fsites\u002Fpermissions-delete)\n- [Get a site](\u002Fdocs\u002Fentities\u002Fsites\u002Fget)\n- [Sites](\u002Fdocs\u002Fentities\u002Fsites)\n","2026-10-16",{},1795343881973]