Adjust stock
POST/inventory/adjustments
Adds delta (negative to remove) to the stock of one item at the outlet in X-Outlet-ID, as the acting user.
Request
- Name the item by
item_type+item_id(send both). deltamust not be 0.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.- The reason must fit the sign of
delta. Loss reasons (damaged,defective,expired,theft,natural_shrinkage,sample_tester,staff_consumption,production_use) need a negativedelta. - Gain reasons (
found_stock,supplier_bonus,return_to_stock) need a positivedelta. The other three take either sign. - A reason that does not fit the sign answers
400 VALIDATION_FAILEDon fieldreason. - An item of
item_type: raw_materialneeds a plan with raw materials and recipes, otherwise403 PLAN_FEATURE_REQUIRED. - An unknown field is ignored.
Behaviour
- Use
Idempotency-Keyto retry safely. - If another system is also your stock master, the two writers can overwrite each other.
Request
Responses
- 201
- 400
- 401
- 403
- 404
- 409
- 422
The posted adjustment
Error envelope
Error envelope
Error envelope
Error envelope
Error envelope
Error envelope