01 · Normal dayShipping
The call fits the contract
The agent calls send_email to the customer on the ticket. Every argument is inside the contract, so the gate forwards it unchanged.
Every decision is a signed ledger entry, allowed calls included, and the email's outcome is recorded too.
02 · Agent trickedShipping
Wrong recipient, refused
Hidden text in a ticket makes the agent call send_email to attacker@evil.com. The recipient is not the ticket's customer, so the gate refuses with scope_mismatch (JSON-RPC -32001). The email server never sees it. A call to an undeclared export_customers is refused as undeclared_tool.
Each refusal can go to a signed webhook, as a Slack or Discord message or raw JSON, and to OpenTelemetry as a span. Hosted alerting and routing are on the roadmap.
03 · Risky but legitimateCLI or broker approval today; Slack approval cards on roadmap
A refund needs a human
The contract says a refund over $100 needs approval. A $350 refund is refused with approval_required until someone signs an approval for that exact call, by hand with cloakpipe approve or through an approval broker. The agent retries and the gate forwards it. Reusing that approval for a different amount is refused with approval_required again: the receipt is bound to the exact call, so it matches no other.
The refusal names the approvers and the call's fingerprint, and the gate sends an approval.requested event to your webhook. The gate can also file the request with an approval broker you run, showing the approver only the arguments the contract lists, and it verifies each approval the broker hands back before using it. Hosted Slack approval cards are on the roadmap.
04 · Did it happen?Shipping · manual reconcile
Reconcile before retry
A create_invoice call is sent but the answer never comes back. The gate marks the operation unknown and refuses every retry with reconcile_before_retry until an operator records what happened with cloakpipe operations reconcile. A retry of a call that already succeeded gets the stored result instead of a second invoice.
Today the outcome turns unknown when the gate or the tool server stops mid-call. Per-call timeouts and reconciliation hooks are on the roadmap.