Stock transfers

The stock transfer object and the allowed CRUD operations on the related resource endpoint

An order can be configured to ship from a specific stock location only (e.g. primary). In this scenario, the number of shipments is minimized by creating one or more stock transfers from the stock location where the items are available to the primary one. Shipping categories are still honored, by creating different shipments.

Stock transfers can also be created outside of the order scope. In this case, they have no relationships with shipments and line items.

Stock transfers are created in draft status and are moved to upcoming as soon as the order associated with the related shipment is placed. At this stage, the necessary stock reservations are created to eventually allow order editing (the stock will be then actually decremented when the stock transfer is completed). If stock transfers are involved, when the order fulfillment process starts all the related shipments are moved to the on_hold status and the related stock transfers status becomes picking (if you want to change the default behavior and put also all the stock transfers on_hold, set the put_stock_transfers_on_hold attribute to true at the inventory model level — you'll then need to manually manage the subsequent status changes). When a shipment is cancelled all the associated stock transfers are also moved to the cancelled status.

All the status changes above are shipment-driven and happen automatically only if the stock transfer is associated with a shipment. Otherwise, you need to manually pass the corresponding trigger attributes (e.g. _upcoming, _picking, etc .).

To avoid dealing with incomplete stock transfers, make sure to move them to completed before the related order approval (or before the moment when you decide to decrement the stock in case you have chosen to do it manually by setting the related flag at the inventory model level).

Data model

Check the related ER diagram and explore the flowchart that illustrates how the stock transfer resource relates to the other API entities.


Last updated