Skip to main content

Get Cost Change

GET 

/api/cost-changes/:costChange

Returns one cost change set with its staged lines (one per FIFO layer: unit cost before and after, units on hand and already consumed at staging time, the original receipt date), its decision history, the restate-versus-prospective impact comparison (impact, the same payload as Get Impact Preview) and what_changed - every cost document on the originating purchase order, dated both by document date and by the day it was entered, so the delta can be read against its sources. what_changed is null when the trigger cannot be traced back to a purchase order.

Required scope: inventory:read

Grant this scope to your token under Settings → Developer → Personal Access Tokens.

restate_blocked_reason is null when restate is a real option, or the sentence explaining why it is refused when the original receipt months are behind the accounting lock date.

Authentication: Requires Bearer token (inventory scope).

Path params:

  • costChange: Cost change set ID

Each cost change also reports what it MOVED, by cost category. composition_movement on the change is the roll-up across its lines, and each line carries composition_before, composition_after and its own composition_movement. The trigger names the document that set the recalculation off, which is not always the document that caused the money to move — re-costing a purchase order picks up any charge on it that had not yet been capitalised. Comparing the movement's categories against the charges the trigger document actually carries is what tells the two apart. Empty on changes recorded before the composition was captured.

Request

Responses

OK

Response Headers
    Content-Type