Set item stock to an exact quantity
PUT/inventory/snapshots/:item_type/:item_id
Counts one item at the outlet in X-Outlet-ID as the acting user: the stock ends at quantity, whatever it was before. Sending the same count again changes nothing.
Request
item_typeisproduct(item_idis a variant id) orraw_material(item_idis a raw material id; needs the raw material plan feature, otherwise403 PLAN_FEATURE_REQUIRED).reasonis one ofdamaged,defective,expired,theft,natural_shrinkage,sample_tester,staff_consumption,production_use,found_stock,supplier_bonus,return_to_stock,recount_adjustment,system_correction,initial_stock_entry; any other value answers400 VALIDATION_FAILED.unit_costis ignored for a raw material.- An unknown field is ignored.
Behaviour
- If another system is also your stock master, the two writers can overwrite each other.
Request
Responses
- 200
- 400
- 401
- 403
- 404
- 409
- 422
The recorded count
Error envelope
Error envelope
Error envelope
Error envelope
Error envelope
Error envelope