Stock items
The stock item object and the allowed CRUD operations on the related resource endpoint
Last updated
The stock item object and the allowed CRUD operations on the related resource endpoint
Last updated
A stock item keeps the inventory of an SKU in a given stock location.
The actual availability of an item may vary depending on active stock reservations. If active stock reservations are associated with a stock item, the available quantity equals the stock item quantity minus the reserved stock quantity.
When you place an order the related stock is reserved. As soon as the order is approved the related stock is released and the stock item quantities get decremented. When a return is approved and the associated items are restocked, the stock item quantities get incremented.
When updating stock items quantities via , existing records may be updated inconsistently: this occurs when the quantity of a stock item is less than the existing reserved stock, which is probably an overselling symptom. To avoid this scenario, we recommend passing the _validate
trigger attribute for each of the imported inputs, as shown in .