1. Containers

VERSION 2.0

Containers (files)

This part or the standard is about organisation of data in datasets.
You will also be able to download sample files.

You will find here

  • Which type of file we can use (ie. xls, csv, xml, api)
  • How data is organised in the file

Before reading this page, we strongly suggest reading the Glossary, so that you will perfectly unserstand the meaning of each terms.

File type

Datas can be exchange through digital file, or REST API.
If using a file, we suggest to use XML, CSV or Excel files.
Be carefull with EXCEL native files (xls and xlsx) since content is highly dependant from regional settings of the source computer. Keep in mind that excel file can be saved as csv.

CSV/XLS file (tabular like file)

Download a sample CSV file

Format

If using csv file, please report to the RFC 4180 standard :
- The field separator has to be comma
- End of line has to be CR/LF
- Coding has to be UTF-8
- Any field quoted with double quote

Organisation of the file

First line is the list of ATTRIBUTES name (ie. columns name), conform to OMEDIS attributes name list.
This list contain both standard attributes and variant attributes (see glossary for distinction).
The order of columns can be set freely. The first line will indicate what data should be considered.

Next lines
Each line is corresponding to one VARIANT (see green line is the sample below).
When one PRODUCT has only one version (no VARIANT), the line is feed by the PRODUCT itself (see yellow line is the sample below).

Rules

  • Different VARIANT of a same PRODUCT needs to strictly share the same NAME attribute value, and be declared in consecutive lines (see the blue lines in the exemple below).
  • Variant attributes values are only used to qualify a specific VARIANT. They have to be leave empty if not defining a specific variant.
    Ex. If one product has every variant with black color, "var-color" has to be left empty (you can put the BLACK word in the NAME of the product)
    Ex. If one product has no variant, all variant attributes have to be left empty

XML file

Download a sample XML file

If using csv file, please conform to XML 1.0 Specification :
- Coding has to be UTF-8

  • Different VARIANT of a same PRODUCT have to be grouped in the same product tag
  • Variant attributes values are only used to qualify a specific VARIANT. They have to be leave empty if not defining a specific variant.
    Ex. If one product has every variant with black color, "var-color" has to be left empty (you can put the BLACK word in the NAME of the product)
    Ex. If one product has no variant, all variant attributes have to be left empty