Kibo clients typically have extensive inventory data to share. While Kibo best practices recommend using the Inventory REST APIs, which provide better error handling and faster responses, the Bulk Data Exchange tools are also available. The Inventory Import process provides current stock-level information to Kibo. This real-time inventory data helps OMS accurately assign orders to fulfillment locations and set product availabilities. Some clients who have multiple fulfillment locations use inventory data to manage inventory levels and assign orders to those multiple locations.
For clients upgrading from a previous version of OMS to the Unified Commerce Platform, the process to import an inventory file remains unchanged. This includes the data fields within the files, as the platform’s translation layer is applied to these files to enable backwards compatibility.
Types of Inventory Import
Two types of Inventory Import processes exist: Refreshes and Updates. Refreshes are more comprehensive and usually sent once per day, providing the total count for all products in the catalog. Updates are normally sent every hour and provide an adjustment to the values sent in the previous Refresh, indicating which product counts should be increased or decreased.
Refresh File Attributes
- Delivered to Kibo once each day
- Represents an accurate stock count for all products
- Includes products with a stock count of zero (0)
Update File Attributes
- Delivered to Kibo throughout the day
- Increments (+2) or decrements (-2) existing stock count(s)
- Sometimes called a ‘trickle’ feed
Getting Started
The client must have identified the SFTP (Secure File Transfer Protocol) site where Kibo picks up the inventory files. There needs to be a provide a username, password, remote path, and remote path archive for the file transmission location.
Creating and Uploading the Files
Inventory data should be submitted as XML or CSV files and compressed into Zip format before being transferred.
A Trigger/Control file should also be created each time data is submitted. The Trigger file tells Kibo that the inventory file is ready to process. This is an empty file with the same file name as the inventory files being submitted, and the extension .done (ex. KIBO_REFRESH_130909121152.zip.done).
The zipped file should be uploaded to the SFTP site followed by the Trigger file.
Naming Inventory Import Files
Inventory files should be named with the following conventions, depending on what type of inventory import it is:
- KIBO_REFRESH_YYMMDDhhmmss
- KIBO_UPDATE_YYMMDDhhmmss
Where:
- _REFRESH_ identifies this file as a Refresh, and should be entered literally.
- _UPDATE_ identifies this file as an Update, and should be entered literally.
- YYMMDD is the year, month, and day represented in two-digit format. For example, 130301 is March 1, 2013
- hhmmss is the time in Pacific Standard Military Time, expressed as hour-minute-second, that the file was created. For example, 205912 is 10:59:12 p.m. PT.
Substitute KIBO with the designated client/company name. This convention makes it easier for Kibo to track the file through its job queues.
Data Elements
These parameters are used in both CSV and XML file formats. When building the file, identify a location name and then follow it with blocks of the item-specific data for each product.
Field | Required | Format | Description |
Location Name | Yes | String | The identifier of the location that is submitting inventory data. Note that this value should actually be the external ID for the location, not the name as stored in the OMS admin. This is due to the inventory system looking for a “Location Name” variable, but requiring it to match the external ID. |
Part Number | Yes | String | The merchant-assigned Part Number for the item. |
UPC | Optional | String | The UPC for the item. |
SKU | Optional | String | The SKU for the item. |
Quantity | Yes | Integer | If this is a Refresh, this is the number of the item in inventory. Examples are 352 and 4. If this is an Update, this value includes a + (plus) or – (minus), and is the change in quantity from the previous submission. Examples are +352 and -4. |
Bin | Optional | Integer | The name of the bin within a location. Used for warehouse and store management. It must exist for the LocationName. |
LTD | Optional | Integer | Custom field used for store prioritization. Kibo will advise you on the type of data to enter in this field if you need to use it. |
Safety Stock | Optional | Integer | Quantity of this item you want to keep in stock to ensure your stock isn’t completely depleted. Both Safety Stock and Floor are optional; most people prefer Safety Stock to Floor. |
Floor | Optional | Integer | Absolute minimum quantity of this item that should be in stock at any time. Both Safety Stock and Floor are optional; the two values are used for similar purposes; most people prefer to use Safety Stock rather than Floor. |
CurrencyID | Optional | Integer | Field defining which currency is used to store the RetailPrice. Required if RetailPrice is passed in. See the Currency API for details |
RetailPrice | Optional | Decimal | The location specific price the product being refreshed. CurrencyID is required if RetailPrice is passed in. |
Attributes | Optional | Array | A list of attributes that are assigned to the item. |
InventoryLocatorName | Optional | String | An identifier to indicate where a particular SKU exists within a location. For example, “Aisle 5” would indicate that the bin this item belongs to is located in Aisle 5. The maximum length is 50. |
Examples
Here is an example import sequence:
- Create the file : KIBO_REFRESH_130909121152.xml (or .csv)
- Compress (zip) the file : KIBO_REFRESH_130909121152.zip
- Upload the zip file.
- Upload a Trigger/Control file : KIBO_REFRESH_130909121152.zip.done
XML File
The following example provides inventory information for two locations and includes only required elements.
<?xml version="1.0" encoding="UTF-8"?> <Inventory> <Location> <LocationName>0001</LocationName> <Item> <PartNumber>883360541099</PartNumber> <SKU>883360541099</SKU> <Quantity>11</Quantity> <SafetyStock>4</SafetyStock> <Floor>1</Floor> <LTD>3</LTD> <Attributes>RESTOCK-CARRIER|RESTOCK-TRUCK</Attributes> <InventoryLocatorName>Aisle 2</InventoryLocatorName> </Item> <Item> <PartNumber>883360541075</PartNumber> <SKU>883360541075</SKU> <Quantity>44</Quantity> <SafetyStock /> <Floor /> <LTD /> <Attributes>RESTOCK-CARRIER</Attributes> <InventoryLocatorName>Aisle 3</InventoryLocatorName> </Item> </Location> <Location> <LocationName>0002</LocationName> <Item> <PartNumber>883360541099</PartNumber> <SKU>883360541099</SKU> <Quantity>11</Quantity> <SafetyStock>4</SafetyStock> <Floor>1</Floor> <LTD>3</LTD> <Attributes>RESTOCK-CARRIER</Attributes> <InventoryLocatorName>Aisle 4</InventoryLocatorName> </Item> <Item> <PartNumber>883360541075</PartNumber> <SKU>883360541075</SKU> <Quantity>44</Quantity> <SafetyStock>5</SafetyStock> <Floor>1</Floor> <LTD>2</LTD> <Attributes>RESTOCK-CARRIER</Attributes> <InventoryLocatorName>Aisle 5</InventoryLocatorName> </Item> </Location> </Inventory>
CSV File
The following example provides inventory information for two locations. Note that CSV has some special requirements:
- The header is optional
- Order of inventory fields matters: LocationName,PartNumber,UPC,SKU,Quantity,Bin,etc.
- String fields must be quoted
LocationName,PartNumber,UPC,SKU,Quantity,Bin,LTD,SafetyStock,Floor,CurrencyID,RetailPrice,Attributes,InventoryLocatorName "0001","PartNumber1","UPC1","SKU1",11,"BinName1",1.0,2,4,1,25.99,,"Aisle 1" "0001","PartNumber2","","SKU1",44,"BinName2",,"Aisle 2" "0002","PartNumber1","UPC1","SKU1",11,,1.0,2,1,,"Aisle 3" "0002","PartNumber2","","SKU2",44,,"Aisle 4"
Additional Resources
Refresh
- http://api.shopatron.com/xsd/InventoryRefresh.xsd
- http://api.shopatron.com/xsd/InventoryRefresh.xml
- http://api.shopatron.com/xsd/InventoryRefresh.csv
Update