Docs

Claude Code integration

Route Claude Code through TokenBeaver's local gateway — same answers, fewer tokens. Works whether you're on an API key or a Claude subscription (Pro or Max).

1. One command

With the CLI installed, run:

tokenbeaver-gateway --install-claude-hooks

That installs Claude Code hooks and a local restore helper. Start a new Claude Code session and you're routed — nothing else to configure.

2. Or from VS Code

Using the extension instead? It wires Claude Code from the status bar — no terminal needed. The gateway install of hooks happens for you when it starts.

3. Verify

Use Claude Code as normal. tokenbeaver-gateway --status shows requests flowing, and your dashboard shows what each session saves. If the gateway is ever unavailable, requests fail open and go directly to Anthropic, so your workflow never breaks.

Undo & troubleshooting

Want it out? tokenbeaver-gateway --uninstall-claude-hooks removes everything. Hooks acting up after an update? Run --install-claude-hooks again, or TokenBeaver: Repair Claude Code Hooks in VS Code.