For AI agents: markdown of this page — /docs-content-en/entities/basket-item-properties/fields.md documentation index — /llms.txt

Basket item property fields

GET /v1/basket-item-properties/fields

Describes basket item property fields for creation, updates, selection, and filtering, and lists grouping fields.

Parameters

Parameter Type Default Description
Parameterrefresh (query) Typestring Defaultfalse DescriptionPass true to retrieve metadata without the cache

Examples

curl — personal key

Terminal
curl "https://vibecode.bitrix24.com/v1/basket-item-properties/fields" \
  -H "X-Api-Key: YOUR_API_KEY"

curl — OAuth application

Terminal
curl "https://vibecode.bitrix24.com/v1/basket-item-properties/fields" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN"

JavaScript — personal key

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/basket-item-properties/fields', {
  headers: {
    'X-Api-Key': 'YOUR_API_KEY',
  },
})

const { success, data } = await res.json()

JavaScript — OAuth application

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/basket-item-properties/fields', {
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
  },
})

const { success, data } = await res.json()

Response fields

Field Type Description
Fieldsuccess Typeboolean DescriptionAlways true on success
Fielddata Typeobject DescriptionBasket item property metadata
Fielddata.fields Typeobject DescriptionField definitions. Each key is a field name and each value describes the field
Fielddata.fields.<field>.type Typestring DescriptionValue type: number or string
Fielddata.fields.<field>.readonly Typeboolean Descriptiontrue marks a read-only field
Fielddata.fields.<field>.createOnly Typeboolean DescriptionPresent as true for basketId, which can only be set at creation
Fielddata.fields.<field>.required Typeboolean DescriptionPresent as true for fields required at creation: basketId, name, value, code
Fielddata.fields.<field>.nullable Typeboolean DescriptionPresent as true for value, code, xmlId, which accept null
Fielddata.fields.<field>.label Typestring DescriptionField label
Fielddata.fields.<field>.description Typestring DescriptionField description
Fielddata.aggregatable Typearray DescriptionFields for groupBy in aggregation: basketId, code
Fielddata.batch Typearray DescriptionBatch write operations: create, update, delete

Basket item property fields

The complete set of schema fields. RO marks a read-only field.

Field Type RO Description
Fieldid Typenumber ROyes DescriptionProperty ID. Source: GET /v1/basket-item-properties
FieldbasketId Typenumber ROno DescriptionBasket item ID. Source: GET /v1/basket-items. Required at creation and cannot be updated
Fieldname Typestring ROno DescriptionProperty name. Required at creation
Fieldvalue Typestring | null ROno DescriptionProperty value. Required at creation
Fieldcode Typestring | null ROno DescriptionProperty symbolic code. Required at creation
Fieldsort Typenumber ROno DescriptionSort order of the property within the item
FieldxmlId Typestring | null ROno DescriptionExternal ID

Response example

JSON
{
  "success": true,
  "data": {
    "fields": {
      "id": {
        "type": "number",
        "readonly": true,
        "label": "ID",
        "description": "ID."
      },
      "basketId": {
        "type": "number",
        "readonly": false,
        "createOnly": true,
        "required": true,
        "label": "Basket item ID",
        "description": "Basket item ID."
      },
      "name": {
        "type": "string",
        "readonly": false,
        "required": true,
        "label": "Name",
        "description": "Name."
      },
      "value": {
        "type": "string",
        "readonly": false,
        "required": true,
        "nullable": true,
        "label": "Value",
        "description": "Value."
      },
      "code": {
        "type": "string",
        "readonly": false,
        "required": true,
        "nullable": true,
        "label": "Code",
        "description": "Code."
      },
      "sort": {
        "type": "number",
        "readonly": false,
        "label": "Sort order",
        "description": "Sort order."
      },
      "xmlId": {
        "type": "string",
        "readonly": false,
        "nullable": true,
        "label": "External ID",
        "description": "External ID."
      }
    },
    "aggregatable": [
      "basketId",
      "code"
    ],
    "batch": [
      "create",
      "update",
      "delete"
    ]
  }
}

Error response example

401 — the API key is missing:

JSON
{
  "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 DescriptionNo Bitrix24 access tokens are configured
HTTP429 CodeRATE_LIMITED DescriptionThe request rate limit was exceeded. Retry after the interval in the Retry-After header

For the full list of common API errors, see Error codes.

See also