Approvals and exception handling
I put a person between the agent and the change, with gated tools, a pending queue, expiry, and a record.
How I deliver it at a customer
- Map decision rightsI list every action the agent can take and mark the ones that change a live system. I give each policy its own ordered list of approver roles, so the queue knows who may answer.
- Gate the tool callsI route every agent tool call through one bridge that blocks reserved schemas and refuses database writes when writes are off. I can also enable a risk router that sends shell, filesystem, package and deploy tools to an isolated sandbox.
- Classify the actionI write the pattern list that the policy engine matches each command against, which labels it allow, confirm or block. Force pushes to main and DROP DATABASE stay blocked, while kubectl delete and helm upgrade need a confirmation.
- Hold for a personA confirm result becomes a pending request instead of a running call, and the agent waits for an answer. That path is built but off by default, so I wire it up and test it in each deployment.
- Route and answerI point approvers at the pending queue at GET /policies/approvals, where a signed-in person posts an approve or reject decision. The stored request keeps the decider id and timestamp, and a failed write throws rather than letting the action run.
- Handle the exceptionsI run a sweep every minute that marks queued requests past the configured approval timeout as expired and emits a timeout event. I set a second sweep to post one note on each work chain left open past the stale threshold.
Tools I use
| Tool | What it does here | Status |
|---|---|---|
| Agent runtime and tool bridge | Runs the agent and sends every tool call through one bridge that blocks reserved schemas and refuses disabled database writes. | Available |
| Command classifier and approval API | Labels each command allow, confirm or block, and stores a confirm request for a person to approve or reject. | Early access |
| Approval queue and audit record (GET /policies/approvals, GET /policies/audit) | Holds pending requests with the decider id and timestamp, and throws when a decision cannot be written. | Early access |
| Policy exception chains in the admin console | Records the ordered approver roles per policy and advances an exception one recorded approver at a time. | Early access |
| Public demo on Cloudflare Workers AI | Runs the approve-or-reject demo on this page with a Llama model, not a customer deployment. | Demo only |
Available means shipped and in use. Early access means built but not generally available. Roadmap means designed, not built. Demo only means it powers this public demo, not customer deployments.
The demo runs an agent that proposes an action against a system and then stops and waits. Nothing runs until you approve or reject, and the page logs your decision with a timestamp.
Open the live demoThe other answers
Gus IT LLC. Contact gus@gusit.de. Claude is a product of Anthropic PBC. Cloudflare and Workers AI are trademarks of Cloudflare, Inc. Llama is a trademark of Meta Platforms, Inc. Other names are trademarks of their respective owners. Gus IT LLC is an independent engineering firm and is not affiliated with or endorsed by these companies.