Audit and gate every tool call an agent makes
Ringlet's event hooks fire on pre-tool-use, tool-use, stop, notify, cost-threshold, and daily-rollup. Wire them to a shell command or webhook to log every tool call, alert on destructive shell commands, or run a pre-flight guard.
The problem
- An AI agent can run arbitrary tools; teams want a record of what it actually did.
- There's no easy hook point to alert on a destructive shell command before it runs.
- Compliance needs an audit trail that survives across sessions.
How Ringlet handles it
Six lifecycle hook points
Hooks fire on `pre-tool-use`, `tool-use`, `stop`, `notify`, `cost-threshold`, and `daily-rollup`. A `pre-tool-use` hook can inspect the tool call before it runs; `tool-use` records what happened.
Shell or webhook targets
Point a hook at a shell command for local audit logs, or a webhook for a central collector. Output is JSON, so it's SIEM-friendly out of the box.
Sandboxed by default
Remote sessions exec the agent inside a sandbox — bwrap on Linux, sandbox-exec on macOS — so tool calls run with least privilege, not full shell access to your machine.
The commands
# Log every tool call to a local audit file
ringlet hooks add work --on tool-use \
--shell 'echo "$RINGLET_TOOL" >> ~/audit.log'
# Alert a central collector on every tool use
ringlet hooks add --all-profiles --on tool-use \
--webhook 'https://audit.yourco.com/agents'
# Pre-flight guard before a tool runs
ringlet hooks add work --on pre-tool-use \
--shell '/usr/local/bin/agent-guard'