What is XML integration? How to import supplier product and stock feeds into your store

What is XML integration and how is it set up? Steps to import products, prices and stock from a supplier XML feed, update frequency and error handling.

FUFerhat UğurluYazSis TeamPublished: November 23, 20268 min read
In short

XML integration means regularly reading a supplier’s or another system’s product, price and stock file in XML format and transferring it to an online store or ERP. The fields in the file are matched to your own product codes, pricing and publishing rules are applied, and faulty or unexpected data is stopped. The update frequency depends on how fast the product sells and how often the supplier refreshes the file.

Your supplier’s website has a product file that is updated every morning. One of your employees downloads it, compares it with your own product table and enters changed prices and sold-out products into your website by hand. When the file runs to thousands of lines, the job either falls behind or contains mistakes: sold-out products stay on sale, and products whose price has changed are sold at the old price. The solution is to have a rule read the file instead of a person; in e-commerce this is called XML integration. This article explains what XML integration is, how it is set up and how to decide how often stock should be updated.

XML integration is a data connection that regularly reads a supplier’s or another system’s product, price and stock file in XML format and transfers it to an online store or ERP. XML is a file format that organises information with tags, so two different systems can read the same file in the same way.

What does an XML file contain and how is it mapped?

The structure of the file varies from supplier to supplier, but most files contain similar fields. Each field carries its own risk during mapping:

Field in the fileWhat is it for?What to watch for when mapping
Product code or barcodeIdentifies the product with a single IDThe supplier’s code differs from yours; you cannot proceed without choosing a matching key.
Product name and descriptionUsed as storefront textThe same text also appears on the sites of the supplier’s other customers; you may need content unique to your own site.
CategoryPlaces the product in the supplier’s category treeThe supplier’s category names do not match your categories one to one.
Price and currencyGives the purchase price and its currencyThe selling price is calculated by a rule; if an exchange rate is involved, how it is updated needs separate thought.
StockReports the quantity at the supplierZero and “no information” are not the same thing; an empty field may not mean out of stock.
Image linkCarries the address of the product photoThe link may stop working one day; decide whether the image will be stored on your side.
Technical specificationsFeeds filters and comparisonsUnits must be consistent; if the same attribute is written differently, the filter falls apart.

How is XML integration set up?

  1. Get access: find out the file’s address, any access details and how often the supplier refreshes the file.
  2. Map the fields: write down in a table which field on the site each field in the file goes to.
  3. Choose the matching key: barcode, supplier code or manufacturer part number? The key must be single and unique.
  4. Define the pricing rule: how will profit margin, exchange rate and rounding be applied to the purchase price?
  5. Set the publishing rule: will a product that appears in the file for the first time go live directly, or wait for approval?
  6. Set up the schedule: how often, and at what times, will the file be read?
  7. Add error logging and alerts: who will be notified, and how, when a file cannot be read, a field is empty or an unexpected change occurs?

How do you write a pricing rule?

The selling price is derived from the purchase price in the file by a rule: purchase price, profit margin, currency conversion if needed, and rounding are applied in that order. The margin does not have to be the same for all products; different rules can be defined by category or brand. What matters is that the rule is written down and its order is known. Whether prices are recalculated when the exchange rate changes should also be decided at the start.

What do you check on the first import?

  • Does the number of products in the file match the number of products created on the site?
  • For randomly selected products, do price, stock and category match the data in the file?
  • Can you see the list of unmatched and skipped products?
  • Was any product created twice, and do the images open?

How often should stock be updated from a supplier XML feed?

There is no single right frequency; the decision depends on four things: how fast the product sells, how often the supplier refreshes the file, how many channels the same stock is sold in, and what wrong stock costs you. Reading the file more often than the supplier refreshes it brings no new information; you also have to respect the request limits the supplier sets.

SituationUpdate needNote
Fast-selling or limited-quantity productFrequentThe risk of selling the same item twice is high; consider a safety buffer for products below the critical level.
Slow-selling product with plenty of stockLess frequentPrice changes may matter more than stock.
Campaign or peak periodIncreasedPlan a rule to return to the usual schedule when the period ends.
Same product sold in more than one channelConsidered together with the number of channelsDefine a single stock source and let the channels draw from it.

Even when price and stock are in the same file, they do not have to be updated at the same frequency. Stock can be read often and price less often; which one needs what, and why, is decided by looking at sales data.

What happens if the supplier file breaks?

Every integration receives broken data one day. Good design consists of rules that keep this from reaching the site:

  • If the file cannot be read, the last correct data is kept and the site does not go live with empty stock.
  • Whether a product that has disappeared from the file counts as “removed” or “stock zero” is decided at the start.
  • If a price changes by an unexpected amount, the update is stopped and waits for approval.
  • Empty or meaningless fields do not overwrite existing data.
  • Every import is logged; you can see how many products were updated and how many returned errors.

How new products and variants behave also needs to be addressed separately. When a new product is added to the file, it can enter the catalogue automatically, wait as a draft to be checked, or not be imported at all. If a product’s sizes or colours arrive as separate lines in the file, they need to be merged as variants of a single product; otherwise the storefront fills up with the same product.

How do you compare XML integration providers?

Instead of listing company names, look at which questions they answer:

  • Do they support multiple suppliers and different file structures?
  • Do they give you the field mapping and pricing rule settings, or do you have to open a request for every change?
  • Are there alert and stop rules for faulty files, empty fields and unexpected changes?
  • Can you see the import logs?
  • Can the same data be transferred to the ERP, the online store and marketplaces together?
  • On what terms do you own your data and settings?

Where are Excel and manual updates enough, and where do they break?

For a small number of products and prices that rarely change, opening the supplier’s file and updating from a spreadsheet is enough. Once the product count runs into the hundreds, the job comes to depend on one person and stops during holidays or sick leave. When updates are late, the site sells sold-out products or shows old prices; customer service makes up for it with cancellations and apology messages. XML integration hands this repetitive work to a rule and leaves the exceptions to people.

E-commerce XML integration: XML, API and webhooks in YazSis Smart E-Commerce

YazSis Smart E-Commerce offers supplier XML, API and webhook infrastructure in its integration layer. Which supplier file is read with which fields, in which direction and how often is decided in the project’s integration step, after your product structure and pricing rules have been worked out. The general principles of the data flow follow the approach we describe on the integration page: a single source for each field, the direction of the flow and error scenarios, logging and retries, and visible integration health.

AI support for product content and SEO text in the catalogue is also part of the package; it can help you prepare content unique to your own site instead of repeating the same supplier text across several sites.

To set up supplier data according to your own product structure, see the setup model on the Smart E-Commerce page.

Frequently asked questions

What is XML integration?

It is a data connection that regularly reads a supplier’s or another system’s product, price and stock file in XML format and transfers it to an online store or ERP.

How is XML integration set up?

You get the file address and access details, map the fields in the file to the fields on the site, define the matching key and pricing rule, set up the publishing rule and schedule, and add error logging and alerts. The scope is worked out in the project analysis according to the supplier and the product structure.

How do you choose between XML integration providers?

Look at the provider’s flexibility in field mapping and pricing rules, its error and alert rules, import logs, support for multiple suppliers and the terms under which you own your data. Instead of relying on a ranking, evaluate every offer with the same questions from your own list of needs.

How often should stock be updated from a supplier XML feed?

It depends on how fast the product sells, how often the supplier refreshes the file, how many channels the stock is sold in and what wrong stock costs. Frequent updates for fast-selling products and less frequent ones for slow sellers may be enough.

What is the difference between XML and an API?

XML is a file format and is usually read at set intervals. An API is a channel through which systems query each other directly; it is better suited to two-way operations such as pulling orders or updating stock. Many projects use both together.

FU
Ferhat Uğurlu · YazSis Team

Builds enterprise software, AI and digital transformation products together with the YazSis team.