Skip to content

Recalculate Planning Settings

POST /api/inventory-planning-settings-recalculate

Required privilege: Inventory Planning / Edit CSRF header required: X-XSRF-TOKEN

Triggers a recalculation of all inventory planning settings (reorder points, safety stock, suggested quantities) based on current demand, forecast, and historical data. This is an asynchronous operation.


Request Body

No request body required. Optionally scope the recalculation:

{
  "item_ids": [55, 56, 57],
  "warehouse_ids": [3]
}
Field Type Required Description
item_ids array | null No Limit recalculation to specific items. Omit for all items
warehouse_ids array | null No Limit to specific warehouses. Omit for all warehouses

Response

{
  "message": "Recalculation job queued.",
  "job_id": "inv-planning-recalc-1234"
}

Use the Jobs API to track job status.


Code Examples

CSRF=$(grep csrf_access_token cookies.txt | awk '{print $NF}')
curl -b cookies.txt -X POST \
  https://acme.knosc.com/api/inventory-planning-settings-recalculate \
  -H "Content-Type: application/json" \
  -H "X-XSRF-TOKEN: $CSRF" \
  -d '{}'