Skip to main content

Import products, SKUs and categories

Description

Allows you to import 3 types of entities at the same time: products, SKUs and categories.

Request URL

Method: POST

https://example.com/api/v1.1/market/products/import

Request parameters

ParameterTypeExampleRequiredDescription
tokenstring"abcdefghijklmnqrstuvwxyz"YesAPI token

Make sure that market roles are available for the token.
custom_fieldsarray of objects
[ 
   {
      "external_id": "1234",
      "name": "product_custom_field",
      "entity_type": "product",
      "required": false,
      "value_type": "unicode",
      "default_value": "data"
   }
]
NoCreating custom fields for the following entities:
  • product
  • SKU
  • order
  • order item

Learn more
categoriesarray of objects
[
   {
      "external_id": "1234",
      "name": "Camera & Photo",
      "parent_external_id": "123"
   }
]
NoCreating categories and subcategories
Learn more
dataarray of objects
[
   {
      "name": "iPhone",
      "product_external_id": "12345678",
      "external_id": "123456"
   }
]
YesData about products and their SKUs

Request example

{
"token": "abcdefghijklmnqrstuvwxyz",
"custom_fields": [
{
"external_id": "test_field_string",
"name": "String field",
"entity_type": "sku",
"required": false,
"value_type": "unicode",
"default_value": "Default value of the sku test field"
}
],
"categories": [
{
"external_id": "test_category_2",
"name": "Test category 2"
}
],
"data": [
{
"name": "Apple iPhone 13 256GB",
"external_id": "sku_test_1",
"price": "1000",
"old_price": "1100",
"currency": "USD",
"description": "SKU description",
"product_external_id": "iphone_test_1",
"categories": ["test_category_2"],
"tags": ["phone", "Apple"],
"manufacturer_name": "Apple",
"url": "https://example.com",
"pictures": ["https://example.com", "https://example.com"],
"count": 10,
"expiration_time": "730",
"is_available": true,
"delivery": true,
"barcode": [23346346, 23546362, 76834566],
"manufacturer_warranty": true,
"custom_fields": {
"test_field_string": "Test field"
},
"regional_data": [
{
"external_id": "region_YnCrJj8Y1",
"price": "75000",
"old_price": "80000",
"currency": "RUB",
"custom_fields": {
"test_field_string": "Test field"
},
"count": 8,
"is_available": true,
"delivery": true
}
]
}
]
}

Response example

{
"error": 0,
"error_text": "",
"result": [
{
"error": 0,
"external_id": "sku_test_1"
}
]
}

Response parameters

ParameterTypeDescription
errorintError code
error_textstringError text
resultarrayProduct IDs that were successfully imported