Get Products
const url = 'https://api-admin.billz.ai/v2/products?page=1&limit=5&search=Nike&include_empty_stocks=false';const options = { method: 'GET', headers: { 'platform-id': '7d4a4c38-dd84-4902-b744-0488b80a4c01', Authorization: 'Bearer <token>' }};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api-admin.billz.ai/v2/products?page=1&limit=5&search=Nike&include_empty_stocks=false' \ --header 'Authorization: Bearer <token>' \ --header 'platform-id: 7d4a4c38-dd84-4902-b744-0488b80a4c01'Коды ошибок: 400 — ошибка валидации входных данных; 404 — объект не найден; 401, 403, 429, 500 — общие для всех методов. Форматы тела и семантика — Коды ответов и ошибки.
Authorizations
Заголовок раздела «Authorizations»Parameters
Заголовок раздела «Parameters»Query Parameters
Заголовок раздела «Query Parameters»Номер страницы; нечисловое значение — 400
Количество на страницу. Нечисловое значение -> 400
Example
5Строка поиска. Ограничена по длине; повторяющиеся паттерны отклоняются
Example
NikeПоля поиска: name, sku, barcode, description, category, brand либо custom_field_id. Передаётся строкой через запятую
Формат yyyy-mm-dd hh:mm:ss, UTC. Неверный формат — 400
Строка true
Header Parameters
Заголовок раздела «Header Parameters»Идентификатор платформы. Для интеграций используется статичное значение.
Responses
Заголовок раздела «Responses»Успешный ответ
object
Количество товаров
Список товаров
object
ИД товара
ИД родителя (для вариаций)
Категории товара
object
ИД бренда
Название бренда
Вариативный ли товар
Наименование
Артикул
Главная фотография
Баркод
Описание
Дата последнего обновления
Единица измерения
object
ИД типа товара
Остатки по точкам
object
Цены по точкам
object
Акции
object
Атрибуты вариации
object
Кастомные характеристики
object
Фотографии
object
Закупочная цена
Валюта закупки
Поставщики
object
Остатки по поставщикам
object
Examplegenerated
{ "count": 1, "products": [ { "id": "example", "parent_id": "example", "categories": [ { "id": "example", "name": "example", "parent_id": "example" } ], "brand_id": "example", "brand_name": "example", "is_variative": true, "name": "example", "sku": "example", "main_image_url": "example", "main_image_url_full": "example", "barcode": "example", "description": "example", "updated_at": "example", "measurement_unit": { "id": "example", "name": "example", "short_name": "example" }, "product_type_id": "example", "shop_measurement_values": [ { "shop_id": "example", "shop_name": "example", "active_measurement_value": 1 } ], "shop_prices": [ { "shop_id": "example", "shop_name": "example", "retail_price": 1, "retail_currency": "example", "supply_price": 1, "supply_currency": "example", "promo_price": 1, "promos": [ { "id": "example", "external_id": "example", "name": "example", "discount_value": 1, "discount_type": "example", "shop_ids": [ "example" ] } ] } ], "product_attributes": [ { "attribute_id": "example", "attribute_value_id": "example", "attribute_value": "example", "attribute_name": "example" } ], "custom_fields": [ { "custom_field_name": "example", "custom_field_system_name": "example", "custom_field_id": "example", "custom_field_value": "example", "from_parent": true } ], "is_marked": true, "photos": [ { "photo_url": "example", "sequence": 1, "is_main": true } ], "supply_price": 1, "supply_currency": "example", "suppliers": [ { "id": "example", "company_id": "example", "name": "example", "session_id": "example", "deleted_at": 1 } ], "product_supplier_stock": [ { "supplier_id": "example", "supplier_name": "example", "shop_id": "example", "measurement_value": 1, "min_supply_price": 1, "max_supply_price": 1, "retail_price": 1, "wholesale_price": 1 } ] } ]}