Skip to main content

Bulk Inventory by lookup key / inventory type

POST 

/inventory/bulk/:lookupKey/:inventoryType

The bulk inventory endpoint is used to create or update inventory records. The products can be identified based on one of their lookup keys. The inventory record type can be either local or supplier.

When looking up an inventory record, the matching fields are: lookupKey, warehouseId and location. If a record already exists it will be updated, otherwise a new record is created.

Available fields

NameRequired
quantity (integer)yes
sku (string)only when lookup key is sku
supplierCode (string)only when lookup key is supplierCode
supplier (string)only when lookup key is supplierCode
id (integer)only when lookup key is id
sourceId (string)only when lookup key is sourceId
source (string)only when lookup key is sourceId
language (string)only when lookup key is sourceId
warehouseId (integer)no
Default value is 0
company (InventoryCompanyUsergroupResource)no
usergroup (InventoryCompanyUsergroupResource)no
location (string)no
Default value is empty
costPrice (integer)no
Default value is product costprice
nextDeliveryDate (date)no
notes (string)no

dateModified is always updated with the current date and time.

Request

Path Parameters

    lookupKey stringrequired

    Lookup key. Read more about product lookup keys

    inventoryType stringrequired

    Inventory type. local or supplier

Body

    inventory

    object[]

  • Array [

  • company

    object

    language string
    source string
    sourceId number
    language string
    location string
    nextDeliveryDate string
    notes string
    quantity number
    source string
    sourceId string

    usergroup

    object

    id number
  • ]

Responses

Bulk supplier inventory by source id - 200 / Bulk local inventory by sourceId - 200 / Bulk supplier inventory by supplier code - 200 / Bulk local inventory by sku - 200 / Bulk local inventory by Id - 200 / Bulk supplier inventory by source id for company and usergroup - 200 / Bulk supplier inventory by source id for company and non existing usergroup - 200

Response Headers

  • Connection

    string

  • Content-Length

    string

  • Date

    string

  • Keep-Alive

    string

  • Return-Format

    string

Schema

    data

    object[]

  • Array [

  • action string
    id number
    success boolean
  • ]

  • messages string[]
    total number
Loading...