Skip to main content

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).
  • delta must not be 0.
  • reason is one of damaged, 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 answers 400 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 negative delta.
  • Gain reasons (found_stock, supplier_bonus, return_to_stock) need a positive delta. The other three take either sign.
  • A reason that does not fit the sign answers 400 VALIDATION_FAILED on field reason.
  • An item of item_type: raw_material needs a plan with raw materials and recipes, otherwise 403 PLAN_FEATURE_REQUIRED.
  • An unknown field is ignored.

Behaviour​

  • Use Idempotency-Key to retry safely.
  • If another system is also your stock master, the two writers can overwrite each other.

Request​

Responses​

The posted adjustment