Bulk importing inventory batches

Use a CSV import to add or update many inventory batches at once instead of editing them one by one. Go to Inventory Batches > Import, upload your CSV, and Freshly emails you the results. Import and export are available on the paid Freshly plan.

Import section in Freshly Inventory Batches

Choose your starting file

You can create and update batches in the same file. Rows with an inventory_batch_id  update that batch. Rows without one create a new batch. Keeping new and updated batches in separate files makes errors easier to fix.

You'll need to be comfortable editing CSV files in a spreadsheet app such as Google Sheets or Microsoft Excel.

Columns Freshly reads

Freshly uses the column names in the first row, so keep them exactly as they appear in the sample or export file. Any other columns (like product_title  or sku ) are ignored, so you can leave them in.

Column Required Notes
variant_id Yes Shopify variant ID. Filled in for you in the sample and export files.
location_id Yes Shopify location ID. The import modal lists the ID for each of your locations. The variant must be stocked at that location.
inventory_batch_quantity Yes A whole number, 0 or more. A blank cell is treated as 0.
inventory_batch_id Updates only Freshly batch ID from the export. Leave blank to create a new batch.
expiry_date No Format YYYY-MM-DD. Leave blank for a batch with no expiry date.
received_date No Format YYYY-MM-DD. Blank means today.
batch_name , batch_number , barcode , invoice_number , description No Batch details.
enable_shopify_sync No Leave blank or set TRUE to adjust Shopify inventory. Set FALSE to change Freshly only.

When enable_shopify_sync  is TRUE (or blank), new batches add their quantity to Shopify and updated batches change Shopify by the difference. This only happens if Preferences > Inventory > Batch quantities added or adjusted on Freshly are reflected in Shopify. is turned on.

If you edit the file in Microsoft Excel, long ID numbers can turn into scientific notation (for example 4.4435E+12) and get saved that way. Format the ID columns as Number with 0 decimal places, or as text, before saving.

Reading the results email

After you click Start import, Freshly processes the file in the background and emails a CSV to your notification email addresses. The email says how many rows succeeded and failed. Each row's result is in the import_status  column:

import_status What to do
Completed Nothing. The row was imported.
location_id is blank or invalid Copy the location ID from the import modal.
variant_id is blank or invalid Check the ID wasn't changed by your spreadsheet app, and that the variant exists in Freshly.
inventory level not available Stock the variant at that location in Shopify, or use a different location_id .
inventory_batch_id is invalid The batch doesn't exist. Remove the ID to create a new batch instead.
expiry_date is invalid format. Please use YYYY-MM-DD Fix the date format.
received_date is invalid format. Please use YYYY-MM-DD Fix the date format.
Something went wrong importing the batch details. Please contact support. Check the quantity isn't negative, then contact support with the file.

Fix the failed rows, delete the rest, and import the file again.

Still need help? Contact Us Contact Us