This applies to protected tool calls that go through the gateway (MCP tool calls covered by a published action policy). Approval holds are a Preview and are off until a workspace turns on action control. A call that never reaches the gateway is not seen at all, and tools without a policy are observed, not held.
What an approval is bound to
When a person approves a held call, the approval is tied to:- the exact arguments (a digest of the full arguments in canonical JSON form, so key order and spacing do not matter but any changed or added value does),
- the API key that proposed the call,
- the tool, its server and the policy version that held it,
- the workspace.
What each attempt gets
Send the approval’s id in theX-Tracelane-Approval-Id header with a call. If the approval does not cover that call, the gateway refuses it, does not contact the tool, and writes one denied_runtime row with a reason to your workspace ledger (signed when a signing key is configured). The row holds a digest of the attempted call, never its arguments. A call whose arguments the tool contract cannot read is refused before the approval is checked and writes no row.
Two things are not refusals:
- Presenting a still-waiting approval with the exact call returns
409 approval_requiredagain and writes nothing new. - Retrying a refused attempt with the same
Idempotency-Keygets the same answer and adds no second row. Retrying a call that already ran, with its originalIdempotency-Key, returns the stored result and runs nothing again.
See the attempts
Each refused attempt appears on the Actions page with the status Blocked; its detail shows the event Refused at runtime. The rows are part of the workspace’s hash-chained, tamper-evident ledger and are checked by the offline verifier like any other row. See Audit ledger.Run the tests yourself
The tests run the gateway’s real approval and execution code against a throwaway local Postgres. Tool effects are simulated; nothing is sent to a real tool or provider.crates/gateway/src/action_control/act19_pg_tests.rs. They fail rather than skip if Postgres is not reachable. The swap sweep runs 33 changed calls and 8 malformed ones against one approval, then runs the genuine call once.
Limits
- Only protected tool calls through the gateway are covered. The tests do not cover calls made directly to a tool.
- A replay is recorded with the reason
approval_mismatch; the answer to the caller is the more specificapproval_not_approved. - Each new attempt (a new
Idempotency-Key) adds one row.