[INTEGRATION]

Route Claude Code through Grepture.

Get full visibility into every Claude Code request your team makes. Track costs, inspect prompts, and protect sensitive data — with a 2-minute setup.

What is Grepture?

Grepture is an open-source AI gateway that sits between your applications and AI providers. It logs every request, tracks token costs, detects sensitive data, and gives you a single dashboard for all your AI traffic. Now it works with Claude Code too.

Set up in 3 steps

1. Create a Grepture account

Sign up at app.grepture.com and grab your API key from the dashboard.

2. Configure Claude Code

Add three environment variables to your Claude Code configuration.

3. Start coding

Every Claude Code request now flows through Grepture. Open the dashboard to see your traffic.

.claude/settings.json
{
  "env": {
    "ANTHROPIC_BASE_URL": "https://proxy.grepture.com/claude",
    "ANTHROPIC_API_KEY": "sk-ant-xxx",
    "ANTHROPIC_CUSTOM_HEADERS": "x-grepture-api-key: grp_xxx"
  }
}
Terminal — Claude Code
$ claude
Claude Code v1.0.8
> Help me refactor the auth middleware to use JWT tokens
I'll help you refactor the auth middleware. Let me start by reading the current implementation.
toolRead src/middleware/auth.ts
toolRead src/config/jwt.ts
I see the current middleware uses session cookies. Here's the plan:
1. Replace cookie parsing with Bearer token extraction
2. Add JWT verification using your existing config
3. Attach decoded user to request context
app.grepture.com/traffic-log
Requests
4
Tokens
8,446
Cost
$0.4221
Recent requests
now200claude-opus-4-6$0.1422
Help me refactor the auth middleware to use JWT...
3s ago200claude-opus-4-6$0.0601
Read src/middleware/auth.ts
8s ago200claude-opus-4-6$0.0492
Read src/config/jwt.ts
15s ago200claude-opus-4-6$0.1706
Analyze session cookie implementation and...

Start observing your AI traffic in 5 minutes

Drop-in SDK. See your first request in under a minute.

Free for up to 1,000 requests/month · No credit card required

Get Started Free