Protect Secrets When Using Claude Code

Claude Code has deep access to your codebase. AxSentinel ensures your secrets stay local.

The Problem

Claude Code operates in your terminal with access to your entire project. It reads files, runs commands, and sends large code contexts to Anthropic's API. If your repo contains .env files, hardcoded credentials, database connection strings, or customer data in fixtures, Claude Code may include them in API requests without you realizing it.

The Solution

Set ANTHROPIC_BASE_URL to the AxSentinel proxy. Every API call Claude Code makes is intercepted, scanned for secrets and PII, and only forwarded if clean. Your workflow doesn't change — Claude Code works exactly the same, but your sensitive data never leaves your machine.

Get Started in Minutes

1

Start the AxSentinel proxy

Run the proxy on port 8990. It will listen for Anthropic API requests.

~/.axsentinel/sentinel --proxy --port 8990
2

Set the environment variable

Add this to your ~/.bashrc, ~/.zshrc, or shell profile so it persists across sessions.

export ANTHROPIC_BASE_URL=http://localhost:8990
3

Use Claude Code normally

Claude Code will automatically route through the proxy. You'll see [telemetry] logs in the proxy terminal when detections occur.

Key Features

Transparent proxy

Claude Code doesn't know the proxy exists. Zero changes to your workflow.

Full context scanning

Scans the entire API payload — file contents, tool results, and conversation history.

Dashboard telemetry

Every detection is logged to your compliance dashboard with provider, source, and detection type.

Works offline

Use --fast for regex-only scanning without an internet connection. Upload results later.

Frequently Asked Questions

Does Claude Code still work through the proxy?
Yes. The proxy forwards clean requests to api.anthropic.com transparently. Claude Code works exactly as before.
What happens when a secret is detected?
In block mode (default), the request is rejected and Claude Code sees an error. In redact mode, the secret is stripped and the request is forwarded.
Does this work with Claude Code's extended thinking?
Yes. The proxy scans the outbound request payload regardless of which Claude features are used.
Can I use this in CI/CD with Claude Code?
Yes. Set ANTHROPIC_BASE_URL in your CI environment and run the proxy as a background process.

Ready to secure your AI workflow?

Free tier includes regex scanning for unlimited developers. Pro adds ML-powered detection and the compliance dashboard.