Replay stored decisions under a candidate policy

Retro-simulation: POST a partial candidate policy (dollars, same shape as the policy update) and a range up to 92 days (defaults to the last 7); every stored decision in the window re-runs through the pure ladders with the candidate overlaid on its recorded context, and the response reports what flips — totals by effect, approved-spend delta, and the changed decisions with before/after codes. Read + compute only: nothing is persisted, debited, or escalated. mode=as_recorded (SIM-1, default) holds budget counters as the engine saw them; mode=sequential (SIM-2) replays in chronological order threading each agent's approved spend forward, so an early would-denial frees budget for a later request. Owner-only.

post/policy/simulate

Request

  • Base URL: https://getsanction.com/api/v1
  • URL: https://getsanction.com/api/v1/policy/simulate
  • Auth: API key in header x-mgmt-key

Request body

wallet_idstring required
fromstring date
tostring date
mode'as_recorded' | 'sequential'

as_recorded (default, SIM-1): each decision replays with its recorded budget state. sequential (SIM-2): replays in chronological order threading each agent's approved spend forward, so an early would-denial frees budget for a later request.

Response

Simulation report

wallet_idstring
fromstring date
tostring date
state'as_recorded' | 'sequential'

Honesty envelope. as_recorded: counters held as the engine saw them, cascade not modeled. sequential: approved spend threaded forward in time (daily/monthly reset at UTC boundaries); subtree/pool caps not yet threaded.

notestring
applied_fieldsstring[]
ignored_fieldsstring[]

Provided candidate fields the simulation cannot honor.

truncatedboolean

Changes

No recorded changes to this operation across all 1 revision of this API.