Dành cho AI agent: markdown của trang này — /docs-content-en/entities/catalog-prices.md chỉ mục tài liệu — /llms.txt

Hiện tại, các bài viết trong tài liệu chỉ có bằng tiếng Anh.

Catalog prices

Product prices: list, retrieve, create, update and delete. A single product can have several prices: prices of different types and, within one type, prices for different quantity ranges. Prices are linked to products from the catalog.

Bitrix24 API: catalog.price.* Scope: catalog

Create a price

POST /v1/catalog-prices

Creates a product price. Fields are passed flat at the JSON root. Without quantity ranges, a product can have only one price of each type; with ranges, one price per range.

Request fields (body)

Field Type Required Description
productId number yes ID of the product the price belongs to. List: GET /v1/catalog-products?filter[iblockId]=<id> (the iblockId value comes from GET /v1/catalogs)
catalogGroupId number yes Price type. Type numbers depend on the Bitrix24 account: the list is GET /v1/catalog-price-types; the base type is the record whose base equals Y
price number yes Price value
currency string yes Price currency, e.g. USD. List: GET /v1/currencies
quantityFrom number no Lower bound of the quantity range
quantityTo number no Upper bound of the quantity range

Examples

curl — personal key

Terminal
curl -X POST "https://vibecode.bitrix24.com/v1/catalog-prices" \
  -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "productId": 7081,
    "catalogGroupId": 1,
    "price": 1500,
    "currency": "USD"
  }'

curl — OAuth application

Terminal
curl -X POST "https://vibecode.bitrix24.com/v1/catalog-prices" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "productId": 7081,
    "catalogGroupId": 1,
    "price": 1500,
    "currency": "USD"
  }'

JavaScript — personal key

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/catalog-prices', {
  method: 'POST',
  headers: {
    'X-Api-Key': 'YOUR_API_KEY',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    productId: 7081,
    catalogGroupId: 1,
    price: 1500,
    currency: 'USD',
  }),
})

const { success, data } = await res.json()
console.log('Price ID:', data.id)

JavaScript — OAuth application

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/catalog-prices', {
  method: 'POST',
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    productId: 7081,
    catalogGroupId: 1,
    price: 1500,
    currency: 'USD',
  }),
})

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

Response fields

Returns the full object of the created price.

Field Type Description
id number Identifier of the created price
productId number Product ID
catalogGroupId number Price type
price number Price value
currency string Price currency
quantityFrom number | null Lower bound of the quantity range
quantityTo number | null Upper bound of the quantity range
priceScale number Price in the Bitrix24 account's base currency. Equals price on creation
extraId number | null Markup identifier (catalog_extra). Deprecated Bitrix24 field
timestampX string Modification date (ISO 8601 with timezone)

Response example

JSON
{
  "success": true,
  "data": {
    "catalogGroupId": 1,
    "currency": "USD",
    "extraId": null,
    "id": 861,
    "price": 1500,
    "priceScale": 1500,
    "productId": 7081,
    "quantityFrom": null,
    "quantityTo": null,
    "timestampX": "2026-09-16T10:02:57.000Z"
  }
}

Error response example

422 — a required field was not provided:

JSON
{
  "success": false,
  "error": {
    "code": "BITRIX_ERROR",
    "message": "Required fields: currency",
    "b24Code": "0"
  }
}

Errors

HTTP Code Description
422 BITRIX_ERROR A required field was not provided — the message lists the missing ones (Required fields: <name>)
422 BITRIX_ERROR The product already has a price of this type, and neither price has a quantity range: Validate price error. Catalog product is allowed has only single price without ranges in price group. Change the existing one via PATCH /v1/catalog-prices/:id
422 BITRIX_ERROR The product has no price of this type for quantities above quantityTo: Invalid quantity range entry: no price is specified for quantity over <quantityTo>. If the product has no price of this type yet, first create a price with quantityFrom one greater than quantityTo and no quantityTo, then repeat the request
422 BITRIX_ERROR The product already has a price of this type without a range, and the new price sets a range: Quantity bounds error: higher bound 0 must be above zero (for the last range). First assign a range to the existing price via PATCH /v1/catalog-prices/:id: for example, for a new price covering 1–10, set quantityFrom: 11 on the existing one, then repeat the request
422 BITRIX_ERROR No price type with this catalogGroupId exists on the portal: Validate price error. Catalog price group is wrong. The response's error.hint points to GET /v1/catalog-price-types and explains what to do if the key owner lacks permission to read that list
400 READONLY_FIELD The body contains id — this field is set by the system and is not accepted on creation
403 SCOPE_DENIED The key lacks the catalog scope
401 TOKEN_MISSING The API key has no configured tokens

The full list of common API errors — Errors.

See also