If you are willing to export data for a delivery service that is yet to be supported in OM, you may use a configurator to create a .cvs or .xls file. Once you choose the ''Export'' button in OM, the format of the export file (CSV, Excel), which needs to be constructed, will be selected based on the delivery service label. 

1. Configuration steps  - creating a connection

Additional settings / Delivery services - select "Custom export" 

Fill in the Delivery type, File name, and other possible required data.

Delivery type = select the Delivery type, which was entered beforehand in Settings/Register (selected register - delivery type). 

Format = choose the format of the export record

Save your entries.

Click on the ''New entry'' button and select among the following:

Title =  column name

Type = value, whose entry you want to convert from order to that column

That needs to be repeated as many times as it is

Save your content. 

3. Data export

Select the entered delivery service in Order Management and by clicking on the ''export'' button, the file prepared in the previous steps will be created. 

The in-depth description of export configuration

Configuration of settings is composed of the following parts:

  • extraFields - general settings of a report
  • columns - assigning columns

Configuration example:

{  "type": "MK_EXPORT",  "delivery_type_id": 1600372916,  "country_id": 1,  "default_additional_service_id_list": [],  "exportFormat": "XLSX",  "additional_delivery_services": [],  "extraFields" : {    "filename" : "Correos_Spain_",    "csv_encoding" : "Cp1250",    "csv_separator" : ";"  },  "columns": [    , { "title": "OrderNumber", "type": "customer_order", "excelWidth": 200 }    , { "title": "Name", "type": "full_name", "excelWidth": 200 }    , { "title": "Fix1", "type": "fix_value", "fixValue" : "ES", "excelWidth": 100}    , { "title": "Empty1", "type": "empty_value", "excelWidth": 100}  ]}

Each column has its own record with the following fields being mandatory:

  • title - title, which has to be different for each column
  • type - a type of data that determines which data will be printed.

Each column may contain the following fields as well (not necessarily):

  1. excelWidth - the column width in the Excel table (if the export is done in Excel). Otherwise, the default value is 100.
  2. stringMaxNOfCharacters - limiting values according to the number of characters.
  3. replaceCharacter and replaceCharacterSeparator replacement of values according to the entered definition (check Example 2)
  4. leftPadCharacter in leftPadSize - if the value does not surpass the length of LeftPadSize, LeftPadCharacter characters are added beforehand (check Example 2)

Note: if parameters such as leftPad, replaceCharacter, and stringMaxNOfCharacters are already given, such are always performed in the following sequence:

  1. replaceCharacter
  2. leftPad
  3. stringMaxNOfCharacters

The following types of columns are supported:

fix_valueFixed valueAn additional column 'fixValue' is requested with fixed value. 
fix_value_if_codFixed value, if an order has a purchase priceAdditional columns 'fixValue' and 'fixValueNoValue' are requested with fixed values.
empty_valueEmpty value

full_nameReceiver's full name
firstnameReceiver's name
Only the receiver's full name is entered into OM. ''Name'' is thus the first word, separated by a space.
secondnameReceiver's surname
Only the receiver's full name is entered into OM. ''Surname'' is thus a string for the first word, separated by a space
streetReceiver's street and house number
street_numberHouse numberThe house number is thus the first string, separated by a space, which contains the number
post_numberReceiver's ZIP Code

placeReceiver's city
provinceReceiver's province
phone_numberReceiver's phone number
emailReceiver's e-mail address
order_dateOrder date
Additional column orderDateFormat is requested with an appropriate value for formatting (i.e. "dd/MM/yyyy")
export_dateData export dateAdditional column orderDateFormat is requested with an appropriate value for formatting (i.e. "dd/MM/yyyy")
customer_orderCustomer's order
customer_order_normalize1Customer's order in a normalized formCommas and spaces should be removed. Example "100 200,300400" -> "100200,300400"
notesAdditional order description
codThe possible value of the purchase priceThrough the parameter "codZeroValue" a value is set, used if there is no purchase price (empty value taken). The parameter "codDecimalSeparator" is intended to determine the delimiter between the whole number and the decimal part of the number (taken ",").
order_sumFull order's value
weight_gTotal weight of an order in grams 
weight_kgTotal weight of an order in kg (rounded to 3 decimals)
productDecriptionList of products on the orderlist of quantities - product code. Separated by a comma. Contains no services. (i.e. 1 - SKU1, 2 - SKU2)
product_skuProduct codeAvailable only if option separate_by_material_product is turned on
product_quantityProduct quantityAvailable only if option separate_by_material_product is turned on

Country 2 characters

Country 3 characters

product_desc2Product Description
Product description separated by a commaIf the option ''Separate the printouts by products'', is selected, it is entered in each row
product_heightProduct heightIn mm
product_widthProduct widthIn mm
product_lengthProduct lengthIn mm
street_romania_blStreet Romania  - label BL
street_romania_scStreet Romania  - label SC
street_romania_etStreet Romania - label ET
street_romania_apStreet Romania - label AP
Order number

Products printout (quantity x SKU)

Products printout (quantity x description)
Printout format can be selected under 'Additional settings > OrderManagement > Select format of notes on labels'

In case of selecting this option, an additional field ''Printout format'' will be shown.
Customer's order & initials
The customer's order and the first two letters of the name
Order's tracking code

Product's customs tariff

Product's country of origin

Price with VAT of a product/piece

Invoice number

The following general configuration of columns is possible:

TypeMeaningDefault value
filenameName of exporting filenot_define
csv_encodingCode table for encoding special characters of the language of the individual country for CSV export
Value example :
csv_separatorThe delimiter between values of columns for CSV export comma
separate_by_material_productEach order is decomposed into combined order - N rows of material productsempty
merge_with_data_exportMerge more exports into one ZIP file.empty 
the URL address for tracking the order
The value will be present only in case of a generated tracking code for the sales order:
tracking_url + tracking_code
Phone number of the delivery service


Example 1: more extensive configuration

{  "type": "MK_EXPORT",  "delivery_type_id": 1600372916,  "country_id": 1,  "default_additional_service_id_list": [],  "exportFormat": "XLSX",  "additional_delivery_services": [],  "extraFields" : {    "filename" : "Correos_Spain_",    "csv_encoding" : "Cp1250",    "csv_separator" : ";"  },  "columns": [    { "title": "OrderData", "type": "order_date", "orderDateFormat" : "dd/MM/yyyy", "excelWidth": 200 }    , { "title": "OrderNumber", "type": "customer_order", "excelWidth": 200 }    , { "title": "Name", "type": "full_name", "excelWidth": 200 }    , { "title": "Street", "type": "street", "excelWidth": 200 }    , { "title": "Province", "type": "province", "excelWidth": 200 }    , { "title": "Post number", "type": "post_number", "excelWidth": 200 }    , { "title": "Fix1", "type": "fix_value", "fixValue" : "ES", "excelWidth": 100}    , { "title": "Empty1", "type": "empty_value", "excelWidth": 100}    , { "title": "Phone", "type": "phone_number_normalize1", "excelWidth": 100}    , { "title": "Fix2", "type": "fix_value", "fixValue" : "33", "excelWidth": 100}    , { "title": "Empty2", "type": "empty_value", "excelWidth": 100}    , { "title": "OrderNumber2", "type": "customer_order_normalize1", "excelWidth": 200, "stringMaxNOfCharacters" : 12}    , { "title": "Fix3", "type": "fix_value", "fixValue" : "FALSE", "excelWidth": 100 }    , { "title": "Empty3", "type": "empty_value", "excelWidth": 100 }    , { "title": "Empty4", "type": "empty_value", "excelWidth": 100 }    , { "title": "Notes", "type": "notes", "excelWidth": 200 }    , { "title": "Fix4", "type": "fix_value", "fixValue" : "V", "excelWidth": 100 }    , { "title": "Fix5", "type": "fix_value", "fixValue" : "1", "excelWidth": 100 }    , { "title": "Fix6", "type": "fix_value", "fixValue" : "1", "excelWidth": 100 }    , { "title": "Empty5", "type": "empty_value", "excelWidth": 100 }    , { "title": "Empty6", "type": "empty_value", "excelWidth": 100 }    , { "title": "Empty7", "type": "empty_value", "excelWidth": 100 }    , { "title": "Fix7", "type": "fix_value", "fixValue" : "Expedidor", "excelWidth": 100 }    , { "title": "COD", "type": "cod", "codZeroValue" : "", "codDecimalSeparator" : ",", "excelWidth": 100 }  ]}

Example 2: use of LeftPad and ReplaceCharacter

Notes :

  • leftPadSize = 5 in leftPadCharacter = '0' means that if the string is shorter than 5 characters, it will get a character 0 beforehand. i.e. "30" -> "00030"
  • replaceCharacterSeparator = "#;". The first character (#) represents the delimiter character between the search string and the string for replacement. The second character(;) represents the delimiter character between individual definitions. Therefore, rule ",# ;!#_;.#" can be decomposed into 3 separate rules according to the character (;) :

        - ",# " - change comma to space

        - "!#_" - change exclamation mark to underscore

        - ".#" - change period to empty string

{  "type" : "MK_EXPORT",  "country_id" : 1,  "default_additional_service_id_list" : [ ],  "extraFields" : {    "csv_encoding" : "Cp1252",    "csv_separator" : ";",    "filename" : "Gologistic_"  },  "exportFormat" : "XLSX",  "columns" : [ {    "title" : "PostalCode",    "type" : "post_number",    "excelWidth" : 200,    "leftPadSize" : 5,    "replaceCharacter" : ",# ;!#_;.#",    "replaceCharacterSeparator" : "#;",    "leftPadCharacter" : "0"  }  ]}