For AI agents: markdown of this page — /docs-content-en/entities/sites/fields.md documentation index — /llms.txt
Site fields
GET /v1/sites/fields
Returns a map of all site fields with their type, read-only flag, label and description. Fields without that flag are writable on create and update.
Examples
curl — personal key
curl "https://vibecode.bitrix24.com/v1/sites/fields" \
-H "X-Api-Key: YOUR_API_KEY"
curl — OAuth application
curl "https://vibecode.bitrix24.com/v1/sites/fields" \
-H "X-Api-Key: YOUR_APP_KEY" \
-H "Authorization: Bearer USER_SESSION_TOKEN"
JavaScript — personal key
const res = await fetch('https://vibecode.bitrix24.com/v1/sites/fields', {
headers: {
'X-Api-Key': 'YOUR_API_KEY',
},
})
const { success, data } = await res.json()
console.log('Fields:', Object.keys(data.fields).length)
JavaScript — OAuth application
const res = await fetch('https://vibecode.bitrix24.com/v1/sites/fields', {
headers: {
'X-Api-Key': 'YOUR_APP_KEY',
'Authorization': 'Bearer USER_SESSION_TOKEN',
},
})
const { success, data } = await res.json()
Response fields
The data object contains a fields map, an aggregatable list of the fields you can group by in aggregation, and a batch list with the operations available in batch mode.
Every field in the fields map is described by the type and readonly keys plus a label and a description — all 22 fields carry both. The type field additionally carries an enum of allowed values, each value with its own label. The nullable: true key is present on the eight fields whose value may be absent: description, xmlId, landingIdIndex, landingId404, landingId503, tplCode, smnSiteId, lang. What an absent value looks like for each of them is shown in the table below.
The label and description values are returned in English. Request headers do not switch the language.
| Field | Bitrix24 | Type | RO | Description |
|---|---|---|---|---|
id |
ID |
number | yes | Site identifier |
title |
TITLE |
string | Name, up to 255 characters | |
code |
CODE |
string | Symbolic code in the URL | |
type |
TYPE |
string | Site type: PAGE, STORE, KNOWLEDGE — created via the API. Responses may also contain VIBE and SMN |
|
active |
ACTIVE |
boolean | yes | Whether the site is active. Read-only: Bitrix24 stores the value neither on create nor on update, so sending the field is refused with 400 READONLY_FIELD. A site is activated by publishing it in the interface |
domainId |
DOMAIN_ID |
number | Domain identifier | |
description |
DESCRIPTION |
string | null | Description, up to 255 characters. null if not set |
|
xmlId |
XML_ID |
string | null | External identifier. null if not set |
|
landingIdIndex |
LANDING_ID_INDEX |
number | null | Home page. Set on update, after the pages are created | |
landingId404 |
LANDING_ID_404 |
number | null | 404 error page. If not assigned — 0 or null |
|
landingId503 |
LANDING_ID_503 |
number | null | 503 error page. If not assigned — 0 or null |
|
deleted |
DELETED |
string | yes | Recycle bin flag: "Y" / "N" |
createdById |
CREATED_BY_ID |
number | yes | Creator. Lookup: GET /v1/users |
modifiedById |
MODIFIED_BY_ID |
number | yes | Last editor. Lookup: GET /v1/users |
dateCreate |
DATE_CREATE |
datetime | yes | Creation date. Bitrix24 locale format, not ISO 8601 |
dateModify |
DATE_MODIFY |
datetime | yes | Last modification date. Bitrix24 locale format |
tplId |
TPL_ID |
number | yes | Site template identifier |
tplCode |
TPL_CODE |
string | null | yes | Template symbolic code. null if the template has no code |
smnSiteId |
SMN_SITE_ID |
string | null | yes | Linked "Site Management" site of type SMN. null for regular sites |
lang |
LANG |
string | null | yes | Language code, for example en. null if not set |
special |
SPECIAL |
string | yes | Bitrix24 service flag: "Y" / "N" |
version |
VERSION |
number | yes | Version of the site's internal structure |
Response example
{
"success": true,
"data": {
"fields": {
"id": {
"type": "number",
"readonly": true,
"label": "Site ID",
"description": "Unique numeric identifier of the site."
},
"title": {
"type": "string",
"readonly": false,
"label": "Title",
"description": "Site name, up to 255 characters. Required on create."
},
"type": {
"type": "string",
"readonly": false,
"label": "Site type",
"description": "Site type. PAGE/STORE/KNOWLEDGE are creatable via the API (KNOWLEDGE needs scope: \"KNOWLEDGE\" on create and update). VIBE (a site built in the constructor) and SMN (a link with the \"Site Management\" module) appear in responses only and are read-only.",
"enum": [
{ "value": "PAGE", "label": "Landing" },
{ "value": "STORE", "label": "Online store" },
{ "value": "KNOWLEDGE", "label": "Knowledge base 2.0" },
{ "value": "VIBE", "label": "Constructor site (read-only)" },
{ "value": "SMN", "label": "Site Management link (read-only)" }
]
},
"active": {
"type": "boolean",
"readonly": true,
"label": "Active",
"description": "Whether the site is active. Read-only: Bitrix24 stores the value neither on create nor on update — landing.site.add and landing.site.update do not declare the field, a new site is always created inactive, and a live round-trip on both verbs answered with a success while the flag stayed off. A site is activated by publishing it in the Bitrix24 interface."
},
"description": {
"type": "string",
"readonly": false,
"nullable": true,
"label": "Description",
"description": "Site description, up to 255 characters. Comes back as null when not set."
}
},
"aggregatable": ["type", "active", "deleted", "lang", "tplId", "domainId", "createdById", "modifiedById"],
"batch": ["create", "update", "delete"]
}
}
5 of 22 fields are shown. The full list is in the table above.
Error response example
403 — no scope:
{
"success": false,
"error": {
"code": "SCOPE_DENIED",
"message": "This endpoint requires 'landing' scope"
}
}
Errors
| HTTP | Code | Description |
|---|---|---|
| 403 | SCOPE_DENIED |
The API key does not have the landing scope |
| 401 | TOKEN_MISSING |
The API key has no configured tokens |
| 429 | RATE_LIMITED |
Rate limit exceeded: 300 requests per minute per portal, all API keys of the portal share one limit. The exact value arrives in the x-ratelimit-limit header (the cap is divided across replicas). Retry after the delay in the Retry-After header |
The full list of common API errors — Errors.