Idempotent on attempt.idempotencyKey, so a genuine retry doesn't double-count.
Optionaloptions: CallOptionsThe subject's velocity over the trailing window ending now; attempts age out as the window slides, with no fixed reset boundary. A subject with no live attempts reads as zero spent and zero attempts, so new subjects need no seeding.
Optionaloptions: CallOptionsRecords the attempt (idempotent on attempt.idempotencyKey) and returns the subject's
windowed velocity including it, in one atomic step serialized per subject — record-and-measure
must be one step (the velocity-limit TOCTOU; see screenRisk in economy.ts).
Optionaloptions: CallOptions
Tracks how much each subject has spent recently — the risk gate's input. Two views: the store-level instance commits on its own connection, the Unit view writes inside the money transaction, so every attempt is counted exactly once whether its operation commits or rolls back.