Skip to main content

Get Decision Impact

GET 

/api/cost-changes/:costChange/decision-impact

Previews what a decision does to the books before it is made. to names the target: restate or prospective (apply a pending change that way, or switch an applied one), or revert (unwind an applied change back to the inbox, or reopen a dismissed one). action is what would actually happen for this set's current state - apply, switch, revert, reopen, or none - and allowed with reason says whether it may proceed.

Required scope: inventory:read

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

to=restate returns allowed: false with reason set to the restate-blocked sentence when any of the set's original receipt months are behind the accounting lock date; the same sentence is what Apply Cost Change and Switch Cost Change Resolution reject with (422) in that case.

For a switch or revert, entries lists every ledger entry the change's revaluations posted: its period and period status (open, closed, locked), amount, whether it is already in the accounting provider (sync: none, individual or batch, with the provider and remote reference), what happens to it (outcome: redated, reversed or discarded), where a switch would re-date it (new_effective_at, new_period, new_period_status), the day a locked period pushes the write to (posts_on) and the provider-side effect (provider_action: none, void, update or batch_modified). summary totals those, and in_flight is true while the previous decision's downstream re-costing is still running.

Authentication: Requires Bearer token (inventory scope).

Path params:

  • costChange: Cost change set ID

Query params:

  • to (required): restate, prospective or revert
  • prospective_date (optional, Y-m-d): the posting day a going-forward switch would use, instead of the set's stamped anchor or the day it was entered

Request

Responses

OK

Response Headers
    Content-Type