For AI agents: markdown of this page — /docs-content-en/entities/person-types/fields.md documentation index — /llms.txt
Payer type fields
GET /v1/person-types/fields
Describes payer type fields for creation, updates, selection, and filtering, and lists the available grouping fields.
Examples
curl — personal key
curl "https://vibecode.bitrix24.com/v1/person-types/fields" \
-H "X-Api-Key: YOUR_API_KEY"
curl — OAuth application
curl "https://vibecode.bitrix24.com/v1/person-types/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/person-types/fields', {
headers: {
'X-Api-Key': 'YOUR_API_KEY',
},
})
const { data } = await res.json()
console.log('Payer type fields:', Object.keys(data.fields))
JavaScript — OAuth application
const res = await fetch('https://vibecode.bitrix24.com/v1/person-types/fields', {
headers: {
'X-Api-Key': 'YOUR_APP_KEY',
'Authorization': 'Bearer USER_SESSION_TOKEN',
},
})
const { data } = await res.json()
Response fields
| Field | Type | Description |
|---|---|---|
Fieldsuccess |
Typeboolean | DescriptionAlways true on success |
Fielddata.fields |
Typeobject | DescriptionField definitions. Each key is a field name, and its value contains the field properties |
Fielddata.fields.<field>.type |
Typestring | DescriptionValue type: number, string, or boolean |
Fielddata.fields.<field>.readonly |
Typeboolean | Descriptiontrue means the field is read-only |
Fielddata.fields.<field>.required |
Typeboolean | DescriptionIncluded as true for name, which is required for creation |
Fielddata.fields.<field>.nullable |
Typeboolean | DescriptionIncluded as true for code and xmlId, which allow null |
Fielddata.fields.<field>.notReturned |
Typeboolean | DescriptionIncluded as true for lid: the field is in the schema but omitted from response objects |
Fielddata.fields.<field>.label |
Typestring | DescriptionField label |
Fielddata.fields.<field>.description |
Typestring | DescriptionField description |
Fielddata.aggregatable |
Typearray | DescriptionFields for groupBy in Aggregate payer types: active, code |
Fielddata.batch |
Typearray | DescriptionBatch write operations: create, update, delete |
Payer type fields
All fields from the schema. The RO column marks read-only fields.
| Field | Type | RO | Description |
|---|---|---|---|
Fieldid |
Typenumber | ROyes | DescriptionPayer type ID. List: GET /v1/person-types |
Fieldname |
Typestring | ROno | DescriptionName. Required for creation and updates |
Fieldcode |
Typestring | null | ROno | DescriptionUnique code. null if not set |
Fieldsort |
Typenumber | ROno | DescriptionSort order |
Fieldactive |
Typeboolean | ROno | DescriptionWhether the type is active |
FieldxmlId |
Typestring | null | ROno | DescriptionExternal ID. null if not set |
Fieldlid |
Typestring | ROyes | DescriptionSite assigned by Bitrix24. Marked notReturned and omitted from response objects |
Response example
{
"success": true,
"data": {
"fields": {
"id": {
"type": "number",
"readonly": true,
"label": "ID",
"description": "ID."
},
"name": {
"type": "string",
"readonly": false,
"required": true,
"label": "Name",
"description": "Name."
},
"code": {
"type": "string",
"readonly": false,
"nullable": true,
"label": "Unique code",
"description": "Unique code."
},
"sort": {
"type": "number",
"readonly": false,
"label": "Sort order",
"description": "Sort order."
},
"active": {
"type": "boolean",
"readonly": false,
"label": "Active",
"description": "Active."
},
"xmlId": {
"type": "string",
"readonly": false,
"nullable": true,
"label": "External ID",
"description": "External ID."
},
"lid": {
"type": "string",
"readonly": true,
"notReturned": true,
"label": "Site assigned by Bitrix24",
"description": "Site assigned by Bitrix24."
}
},
"aggregatable": [
"active",
"code"
],
"batch": [
"create",
"update",
"delete"
]
}
}
Error response example
401 — the API key is missing:
{
"success": false,
"error": {
"code": "MISSING_API_KEY",
"message": "API key required. Pass via X-Api-Key header."
}
}
Errors
| HTTP | Code | Description |
|---|---|---|
| HTTP403 | CodeSCOPE_DENIED |
DescriptionThe API key lacks the sale scope |
| HTTP401 | CodeMISSING_API_KEY |
DescriptionThe X-Api-Key header is missing |
| HTTP401 | CodeTOKEN_MISSING |
DescriptionThe API key has no configured tokens |
| HTTP429 | CodeRATE_LIMITED |
DescriptionRequest limit exceeded: 300 per minute per portal, shared by all API keys for the portal. The exact value is in the x-ratelimit-limit header. Retry after the delay in the Retry-After header |
For the full list of common API errors, see Error codes.