Supplier catalogs

How to keep only YML offers with delivery=true

2026-06-29
Task

The YML contains products with delivery=true, delivery=false, and no delivery. This catalog needs only items where delivery is allowed.

Short answer

Add an export condition to offer: delivery must match regular expression ^(true|1|yes)$ (matches true, 1, or yes from start to end).

How to do it in Eofferix

  1. In the XML/YML snapshot, select the repeated offer node.

  2. Open the node settings.

    Opening offer settings
    The animation shows opening settings for the repeated product node.
  3. Option without a regular expression: add an export condition on delivery - Equals true.

    Export condition
    This option works when the supplier always sends exactly true or false.
  4. Regular expression option: add an export condition on delivery - Regular expression ^(true|1|yes)$ (matches true, 1, or yes from start to end).

    Export condition
    Use this option when the supplier can write allowed delivery in several ways.

Before / after

Before

source data
<yml_catalog date="2026-06-29 10:00">
  <shop>
    <offers>
      <offer id="YML-26001">
        <name>Hudson lamp</name>
        <price>1290.00</price>
        <delivery>true</delivery>
      </offer>
      <offer id="YML-26002">
        <name>Parker chair</name>
        <price>8400.00</price>
        <delivery>false</delivery>
      </offer>
      <offer id="YML-26003">
        <name>Harbor shelf</name>
        <price>990.00</price>
      </offer>
    </offers>
  </shop>
</yml_catalog>

After

result
<yml_catalog date="2026-06-29 10:00">
  <shop>
    <offers>
      <offer id="YML-26001">
        <name>Hudson lamp</name>
        <price>1290.00</price>
        <delivery>true</delivery>
      </offer>
    </offers>
  </shop>
</yml_catalog>

Process data faster with Eofferix

Create a free account to automate catalogs and price lists around your own rules.

Sign up