[{"data":1,"prerenderedAt":7},["ShallowReactive",2],{"docs-entities\u002Fsites\u002Fai\u002Fstatus":3,"docs-tabs-entities\u002Fsites\u002Fai\u002Fstatus":6},{"content":4,"lastmod":5},"## Get a generation status\n\n`GET \u002Fv1\u002Fsites\u002Fai\u002Fstatus`\n\nReads the current state of a generation started by the same user.\n\n## Parameters\n\n| Parameter | Type | Required | Default | Description |\n|---|---|---|---|---|\n| `id` (query) | number | yes | — | Generation identifier from [start](.\u002Fgenerate.md) |\n\n## Examples\n\n### curl — personal key\n\n```bash\ncurl -X GET \"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fsites\u002Fai\u002Fstatus?id=11\" \\\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\u002Fsites\u002Fai\u002Fstatus?id=11\" \\\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\u002Fai\u002Fstatus?id=11\", {\n  \"method\": \"GET\",\n  \"headers\": {\n    \"X-Api-Key\": \"YOUR_API_KEY\"\n  }\n});\nconst result = await res.json();\nconsole.log(result);\n```\n\n### JavaScript — OAuth application\n\n```javascript\nconst res = await fetch(\"https:\u002F\u002Fvibecode.bitrix24.com\u002Fv1\u002Fsites\u002Fai\u002Fstatus?id=11\", {\n  \"method\": \"GET\",\n  \"headers\": {\n    \"X-Api-Key\": \"YOUR_APP_KEY\",\n    \"Authorization\": \"Bearer USER_SESSION_TOKEN\"\n  }\n});\nconst result = await res.json();\nconsole.log(result);\n```\n\n## Response fields\n\n| Field | Type | Description |\n|---|---|---|\n| `success` | boolean | `true` on success |\n| `data` | object | Generation state |\n| `data.id` | number | Generation identifier |\n| `data.status` | string | `running`, `completed` or `failed` |\n| `data.siteId` | number | Generated site identifier, 0 until created; [sites](..\u002Fget.md) |\n| `data.pageId` | number | Generated page identifier, 0 until created; [pages](\u002Fdocs\u002Fentities\u002Fpages\u002Fget) |\n| `data.draftSiteId` | number | Draft site identifier on failure, 0 otherwise |\n| `data.draftPageId` | number | Draft page identifier on failure, 0 otherwise |\n| `data.message` | string | Human-readable state; use status for branching |\n| `data.error` | string \\| null | Failure reason or null |\n| `data.errorDetails` | string \\| null | Request-limit detail or null |\n\n## Response example\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"id\": 11,\n    \"status\": \"running\",\n    \"siteId\": 0,\n    \"pageId\": 0,\n    \"draftSiteId\": 0,\n    \"draftPageId\": 0,\n    \"message\": \"Generating a site\",\n    \"error\": null,\n    \"errorDetails\": null\n  }\n}\n```\n\n## Error response example\n\n```json\n{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"BITRIX_ERROR\",\n    \"message\": \"The action could not be completed. Check the identifier\",\n    \"b24Code\": \"LANDING_AI_SITE_GENERATION_NOT_FOUND\"\n  }\n}\n```\n\n## Errors\n\n| HTTP | Code | Description |\n|---|---|---|\n| 400 | `INVALID_PARAMS` | Bitrix24 refused the request |\n| 401 | `MISSING_API_KEY`, `INVALID_API_KEY`, `TOKEN_MISSING` | Missing or unusable credentials |\n| 403 | `SCOPE_DENIED` | The key lacks the landing scope |\n| 403 | `WRITE_BLOCKED_READONLY_KEY` | The key forbids writes |\n| 422 | `BITRIX_ERROR` | Missing generation or a generation of another user; `b24Code` is `LANDING_AI_SITE_GENERATION_NOT_FOUND` |\n\n[Common errors](\u002Fdocs\u002Ferrors).\n\n## Known specifics\n\nReading a completed or failed generation can make Bitrix24 finalize or release the draft binding and record a moderation refusal. Checking the status therefore requires write access; a READONLY key receives `403 WRITE_BLOCKED_READONLY_KEY`. The platform does not retry a status request after a 5xx error.\n\nCalls run as the webhook owner or the user whose OAuth token the key uses. Read the result through [generation status](.\u002Fstatus.md): `running`, `completed` or `failed`.\n\n## See also\n\n- [AI site generation](..\u002Fai.md)\n","2026-11-13",{},1794739417982]