Claude Code Setup
Omnodex’s primary integration is with Claude Code via the hooks system. This provides the deepest level of tracing with zero performance overhead.
This guide applies to all Claude Code surfaces: the CLI (claude command in a terminal), and the IDE extension (VS Code and compatible editors). The hook is registered globally in your Claude Code settings, so it activates automatically regardless of how you launch Claude Code.
How the Integration Works
Section titled “How the Integration Works”Claude Code supports hooks that fire at specific points during execution. Omnodex registers as a hook that captures:
- Every tool invocation (file reads/writes, bash commands, web searches, MCP calls)
- The parameters passed to each tool
- The results returned
- Session start and end events
The hook fires asynchronously and outside Claude’s context window. This means:
- Claude never sees the hook output (zero token overhead)
- The hook cannot slow down or block Claude’s execution
- There is no way for the hook to influence Claude’s behavior
Installation
Section titled “Installation”-
Install the hook:
Terminal window npx omnodex install claude-code -
Verify it is registered:
Terminal window npx omnodex statusYou should see output confirming the Claude Code hook is active.
-
Use Claude Code normally. Every session from this point forward is traced.
What Gets Traced
Section titled “What Gets Traced”| Event Type | Description |
|---|---|
tool.invoked | A tool was called (includes tool name, parameters, result) |
file.read | A file was read from disk |
file.write | A file was written or modified |
credential.used | An API key or token was referenced |
network.request | An outbound HTTP request was made |
session.start | A Claude Code session began |
session.end | A Claude Code session ended |
Viewing Results
Section titled “Viewing Results”After a Claude Code session completes (or while it is running), you can view traced events:
# Open the live dashboardnpx omnodex dashboard
# Or run detection on collected eventsnpx omnodex detect
# Or view a text-based reportnpx omnodex reportTroubleshooting
Section titled “Troubleshooting”Hook not firing:
- Confirm the hook is registered with
npx omnodex status - Check that your Claude Code version supports hooks
- Verify
OMNODEX_HOMEpoints to a writable directory
Events not appearing:
- Events are written asynchronously. There may be a brief delay (typically under 1 second).
- Check
$OMNODEX_HOME/events.jsonlto see if events are being written
Next Steps
Section titled “Next Steps”- Running Detection - Configure risk detection rules
- Using the Dashboard - Navigate the real-time dashboard