Implementing Product Import from 1C (CommerceML/XML)

Every new project with 1C brings a surprise: the XML structure differs from the previous configuration. The `Name` field may be required, while `SKU` may be missing. Product groups are nested unevenly, and images are stored in a ZIP archive with unpredictable paths. There is no universal parser — a

Development and maintenance of all types of websites:

Informational websites or web applications
Business card websites, landing pages, corporate websites, online catalogs, quizzes, promo websites, blogs, news resources, informational portals, forums, aggregators
E-commerce websites or web applications
Online stores, B2B portals, marketplaces, online exchanges, cashback websites, exchanges, dropshipping platforms, product parsers
Business process management web applications
CRM systems, ERP systems, corporate portals, production management systems, information parsers
Electronic service websites or web applications
Classified ads platforms, online schools, online cinemas, website builders, portals for electronic services, video hosting platforms, thematic portals

These are just some of the technical types of websites we work with, and each of them can have its own specific features and functionality, as well as be customized to meet the specific needs and goals of the client.

Our competencies:

Frequently Asked Questions

Latest works

  • image_web-applications_feedme_466_0.webp
    Development of a web application for FEEDME
    1285
  • image_ecommerce_furnoro_435_0.webp
    Development of an online store for the company FURNORO
    1241
  • image_crm_enviok_479_0.webp
    Development of a web application for Enviok
    982
  • image_crm_chasseurs_493_0.webp
    CRM development for Chasseurs
    1033
  • image_website-sbh_0.webp
    Website development for SBH Partners
    1104
  • image_website-_0.webp
    Website development for Red Pear
    554

Every new project with 1C brings a surprise: the XML structure differs from the previous configuration. The Name field may be required, while SKU may be missing. Product groups are nested unevenly, and images are stored in a ZIP archive with unpredictable paths. There is no universal parser — a mechanism that adapts to a specific export is needed. We have specialized in 1C integrations for over 8 years and completed more than 100 projects. Our experience allows us to anticipate problem areas before development begins and guarantee stable exchange even if the configuration changes. If you need a reliable product import from 1C, contact us — we will analyze your export within one day.

CommerceML is a data exchange standard recommended by 1C for transferring catalogs and orders between systems. Below we break down what it is.

Why CommerceML import requires customization?

Even with a standard export, deviations are possible: missing GUID, non-standard property names, group nesting more than 3 levels. Without field mapping, the site will either lose some data or crash with an error. We configure the correspondence between XML fields and your site models during the analysis phase.

CommerceML Standard

1C exports data in ZIP archives with several types of XML files:

import.zip ├── import.xml — product catalog, categories, properties ├── offers.xml — warehouses, prices, stock └── import0.xml — catalog continuation (when splitting into files) 

Structure of import.xml:

<?xml version="1.0" encoding="UTF-8"?> <КоммерческаяИнформация ВерсияСхемы="2.10"> <Каталог> <Группы> <Группа> <Ид>f47ac10b-58cc-4372-a567-0e02b2c3d479</Ид> <Наименование>Электроника</Наименование> <Группы> <Группа> <Ид>6ba7b810-9dad-11d1-80b4-00c04fd430c8</Ид> <Наименование>Смартфоны</Наименование> </Группа> </Группы> </Группа> </Группы> <Товары> <Товар> <Ид>550e8400-e29b-41d4-a716-446655440000</Ид> <Артикул>IPH-15-PRO-256</Артикул> <Наименование>iPhone 15 Pro 256GB Natural Titanium</Наименование> <ЗначенияСвойств> <ЗначениеСвойства> <Ид>color-property-id</Ид> <Значение>Natural Titanium</Значение> </ЗначениеСвойства> </ЗначенияСвойств> <Картинка>images/iphone15pro.jpg</Картинка> </Товар> </Товары> </Каталог> </КоммерческаяИнформация> 

How is the exchange protocol organized?

1C initiates exchange via HTTP requests to the site. The site implements a handler at specific URLs:

GET /1c-exchange/?type=catalog&mode=checkauth GET /1c-exchange/?type=catalog&mode=init POST /1c-exchange/?type=catalog&mode=file&filename=import.zip GET /1c-exchange/?type=catalog&mode=import&filename=import.xml 

Sequence:

  1. checkauth — 1C checks authentication
  2. init — gets limits (maximum file size, zip or not)
  3. file — uploads XML files
  4. import — requests import of a specific file

Handler implementation (PHP/Laravel)

class OnecExchangeController extends Controller { public function handle(Request $request) { $mode = $request->query('mode'); return match($mode) { 'checkauth' => $this->checkAuth($request), 'init' => $this->init(), 'file' => $this->uploadFile($request), 'import' => $this->importFile($request), default => response('failure', 400), }; } private function checkAuth(Request $request): Response { // 1C sends login/password in Basic Auth if (!$this->validateCredentials($request)) { return response("failure\nInvalid login or password"); } $cookie = Str::random(32); Cache::put("1c_session_{$cookie}", true, 600); return response("success\nCOOKIE\n1c_session={$cookie}"); } private function init(): Response { return response(implode("\n", [ 'zip=yes', 'file_limit=' . (32 * 1024 * 1024), // 32MB ])); } private function uploadFile(Request $request): Response { $filename = $request->query('filename'); $request->file('file')->storeAs('1c-exchange', $filename); return response('success'); } private function importFile(Request $request): Response { $filename = $request->query('filename'); ImportFrom1cJob::dispatch($filename); return response('success'); } } 

XML Parsing

1C XML uses Cyrillic tags in a namespace. Parsing via SimpleXML/DOMDocument is straightforward:

class CommerceMLParser { public function parseImport(string $xmlPath): void { $xml = simplexml_load_file($xmlPath, 'SimpleXMLElement', LIBXML_NOCDATA); $catalog = $xml->Каталог; // Recursively process the category tree $this->processGroups($catalog->Группы->Группа); // Products foreach ($catalog->Товары->Товар as $item) { $this->processProduct($item); } } private function processProduct(SimpleXMLElement $item): void { $guid = (string) $item->Ид; $sku = (string) $item->Артикул; $name = (string) $item->Наименование; // Product properties $attributes = []; foreach ($item->ЗначенияСвойств->ЗначениеСвойства as $prop) { $attributes[(string)$prop->Ид] = (string)$prop->Значение; } Product::updateOrCreate( ['onec_guid' => $guid], ['sku' => $sku, 'name' => $name, 'attributes' => $attributes] ); } } 

Processing the offers.xml file (prices, stock) is analogous. After parsing the attributes, database records are updated:

public function parseOffers(string $xmlPath): void { $xml = simplexml_load_file($xmlPath); $packageOffers = $xml->ПакетПредложений; foreach ($packageOffers->Предложения->Предложение as $offer) { $guid = (string) $offer->Ид; $price = (float) $offer->Цены->Цена->ЦенаЗаЕдиницу; $stock = (int) $offer->Количество; Product::where('onec_guid', $guid)->update([ 'price' => $price, 'stock' => $stock, ]); } } 

Asynchronous import

Large catalogs (10,000+ items) cannot be processed synchronously — 1C expects a response within seconds. Solution:

  • The file is saved immediately (uploadFile)
  • importFile returns success immediately
  • Processing runs in the background via Laravel Queue / Celery
  • Progress is available through a separate endpoint or admin interface

How are images handled during import?

1C exports image paths relative to the archive. Processing:

  1. Unzip the archive into a temporary directory
  2. Process images (resize, convert to WebP)
  3. Upload to CDN/S3
  4. Update database records
Image processing example
$image = Image::make(storage_path("tmp/{$path}")); $image->fit(800, 800); $image->encode('webp', 80); $s3->put("products/{$guid}.webp", $image->encoded); Product::where('onec_guid', $guid)->update(['image' => "products/{$guid}.webp"]); 

How to handle catalogs >10,000 items?

For large catalogs, we use streaming parsing via XMLReader. This allows processing XML files up to 500 MB without memory overflow. Background queues (RabbitMQ, Redis) ensure that import does not block the site. Custom integration reduces exchange errors by 3 times compared to standard modules.

Timeline and cost

Import of products from a single 1C configuration (catalog + prices + stock): 8–12 business days. Includes testing on real client data and debugging edge-cases of the specific 1C configuration. Cost is calculated individually; savings on manual catalog filling offset the investment in the first months.

What's included in the work

Stage Result
1C export analysis Description of XML structure, field mapping
Handler development Controller with routes, parsers
Queue setup Background import via Laravel Queue
Image processing Resize, WebP, upload to S3
Testing Import of real catalog, edge-case verification
Documentation Administrator guide for running exchange
Training Demo of import process, Q&A
Post-launch support 30 days of monitoring and bug fixes

Comparison of approaches: ready-made modules vs custom development

Criteria Ready-made module (e.g., "1C-Bitrix: Data Exchange") Custom integration
Adaptation to 1C configuration Limited by standard, frequent discrepancies Full control over mapping
Performance Depends on module implementation Optimized for your catalog
Support for non-standard fields Only standard properties Any fields, additional transformations
Cost Free or inexpensive Investment, recouped by stability
Implementation time From 1 day 8–12 days

Custom development often turns out cheaper in the long run — especially for companies with complex nomenclature (1000+ items, many characteristics). We guarantee stable exchange even if the 1C configuration changes within the warranty period.

For an accurate timeline and budget estimate, contact our engineers. Get a consultation through the form on the website or by phone. We will analyze your export for free and offer an optimal solution.