## Read a page block

`GET /v1/pages/:pageId/blocks/:blockId`

Returns the metadata of one page block. The draft is always read, so unpublished blocks are visible too.

Requires the `landing` scope. A read-only key works. No request body is sent.

## Parameters

| Parameter | Type | Required | Description |
|----------|-----|:-----:|----------|
| `pageId` (path) | number | yes | Page ID. List: [`GET /v1/pages`](/docs/entities/pages/list) |
| `blockId` (path) | number | yes | ID of a block on page `pageId`. List: [`GET /v1/pages/:pageId/blocks`](/docs/entities/pages/blocks/list) |
| `scope` (query) | string | no | Site type: `KNOWLEDGE` — knowledge base, `GROUP` — workgroup site, `MAINPAGE` — main page. Omit the parameter for pages of other sites |

## Examples

### curl — personal key

```bash
curl "https://vibecode.bitrix24.com/v1/pages/3/blocks/4975" \
  -H "X-Api-Key: YOUR_API_KEY"
```

### curl — OAuth application

```bash
curl "https://vibecode.bitrix24.com/v1/pages/3/blocks/4975" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN"
```

### JavaScript — personal key

```javascript
const response = await fetch("https://vibecode.bitrix24.com/v1/pages/3/blocks/4975", {
  headers: {"X-Api-Key": "YOUR_API_KEY"},
})
const result = await response.json()
if (!response.ok) throw new Error(result.error.message)
console.log(result.data)
```

### JavaScript — OAuth application

```javascript
const response = await fetch("https://vibecode.bitrix24.com/v1/pages/3/blocks/4975", {
  headers: {"X-Api-Key": "YOUR_APP_KEY", "Authorization": "Bearer USER_SESSION_TOKEN"},
})
const result = await response.json()
if (!response.ok) throw new Error(result.error.message)
console.log(result.data)
```

## Response fields

| Field | Type | Description |
|------|-----|----------|
| `success` | boolean | Always `true` on success |
| `data` | object | Block metadata |
| `data.id` | number | Block ID |
| `data.pageId` | number | ID of the page the block belongs to |
| `data.code` | string | Block code from the catalog. List of codes: [`GET /v1/block-repository`](/docs/entities/pages/catalog) |
| `data.name` | string | Block name |
| `data.active` | boolean | Whether the block is active in the page draft |
| `data.dateCreate` | string \| null | Creation date in ISO 8601 format without a timezone — the Bitrix24 account's local time |
| `data.dateModify` | string \| null | Last modification date in the same format |
| `data.createdById` | number \| null | ID of the employee who created the block. List: [`GET /v1/users`](/docs/entities/users/list) |
| `data.modifiedById` | number \| null | ID of the employee who last modified the block. List: [`GET /v1/users`](/docs/entities/users/list) |

## Response example

```json
{
  "success": true,
  "data": {
    "id": 4975,
    "pageId": 3,
    "code": "26.3.separator",
    "name": "Downward color transition",
    "active": true,
    "dateCreate": "2021-11-25T19:12:32",
    "dateModify": "2026-02-09T23:01:30",
    "createdById": 1,
    "modifiedById": null
  }
}
```

## Error response example

404 — the block belongs to another page:

```json
{
  "success": false,
  "error": {
    "code": "ENTITY_NOT_FOUND",
    "message": "Block not found in this page."
  }
}
```

## Errors

| HTTP | Code | Description |
|------|-----|----------|
| 404 | `ENTITY_NOT_FOUND` | `Block not found in this page.` — the block exists but belongs to another page |
| 404 | `ENTITY_NOT_FOUND` | `Block or page not found.` — no block or page with these IDs exists |
| 400 | `INVALID_PARAMS` | `pageId and blockId must be positive safe integers.` — `pageId` or `blockId` is not a positive integer |
| 400 | `INVALID_SCOPE` | `scope` is not `KNOWLEDGE`, `GROUP` or `MAINPAGE` |
| 502 | `BITRIX_INVALID_RESPONSE` | `Bitrix24 returned an invalid block.` or `Bitrix24 returned a different block.` — Bitrix24 returned an unexpected result |
| 502 | `BITRIX_INVALID_RESPONSE` | `Bitrix24 block response exceeds the 8 MiB limit.` — the Bitrix24 response is larger than 8 MiB |
| 422 | `BITRIX_ERROR` | Bitrix24 rejected the request. The error text comes from Bitrix24 |
| 403 | `SCOPE_DENIED` | The API key does not have the `landing` scope |
| 403 | `BITRIX_ACCESS_DENIED` | The Bitrix24 user the key was issued for has no permission to read the page |
| 401 | `TOKEN_MISSING` | The API key has no configured tokens |
| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |
| 401 | `INVALID_API_KEY` | The key in `X-Api-Key` is not found or has been revoked |
| 409 | `LANDING_MODULE_NOT_ENABLED` | The Sites module is unavailable on the Bitrix24 account |
| 409 | `PORTAL_ADDRESS_CHANGED` | The on-premise Bitrix24 moved to a new address, but the key's webhook was issued for the old one. Reissue the key's webhook |
| 429 | `RATE_LIMITED` | The Bitrix24 request limit is exceeded. Retry the request in 1-2 seconds |
| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 did not respond or responded with a server error |
| 503 | `BITRIX_TIMEOUT` | Bitrix24 did not respond in the allotted time |

Full list of common API errors — [Errors](/docs/errors).

## Known specifics

- **Links with credentials are hidden.** A response string that contains a Bitrix24 webhook URL or a token in the URL query parameters comes back as `[REDACTED]`.

## See also

- [Block content](/docs/entities/pages/block-content)
- [List page blocks](/docs/entities/pages/blocks/list)
- [Catalog manifest](/docs/entities/pages/catalog-manifest)
- [Pages](/docs/entities/pages)
