Routing Claude API traffic to control costs after Max subscription change

API billing migration and cost implications
As of noon PT, Anthropic's Max subscription no longer covers usage from third-party tools like OpenClaw. All OpenClaw users are now on API billing with these rates:
- Claude Opus 4.6: $5 per million input tokens, $25 per million output tokens
- Claude Sonnet 4.6: $3 per million input tokens, $15 per million output tokens
- Claude Haiku 4.5: $1 per million input tokens, $5 per million output tokens
A heavy OpenClaw session on Opus can cost $1-4, while the same session on Sonnet costs $0.20-0.80 with similar results for most tasks.
The routing solution
Most OpenClaw operations don't require Opus: heartbeat checks, file reads, summaries, routing decisions, and short tool calls can all be handled by Sonnet. Without a routing layer, every request hits your default model, potentially wasting Opus budget on simple tasks.
A local proxy routes Claude requests by complexity: simple tasks go to Sonnet automatically, complex ones escalate to Opus. This approach has significantly reduced costs without quality loss on important tasks.
The proxy is open source and installable via npm: npm install -g @relayplane/proxy
Detailed documentation and discussion is available on r/ClaudeCode, where the solution has received 52K views.
📖 Read the full source: r/openclaw
👀 See Also

SIDJUA V1.0: Self-Hosted Governance Platform for AI Agents
SIDJUA V1.0 is a free, self-hosted governance platform for AI agents that runs on Docker, including Raspberry Pi. It provides mandatory checkpoints for agent tasks, encrypted credential storage, network isolation, and granular budget controls.

Claude-Code v2.1.63 adds HTTP hooks, slash commands, and fixes memory leaks
Claude-Code v2.1.63 introduces HTTP hooks for JSON-based external calls, adds /simplify and /batch slash commands, and fixes multiple memory leaks in long-running sessions. The release also improves MCP server handling and VSCode integration.

Git pre-commit hook prevents AI coding agents from committing with stale documentation
A developer created a Git pre-commit hook that blocks commits when documentation files are outdated, specifically addressing issues with AI coding agents like Claude Code, Cursor, Windsurf, and Copilot. The tool exits with error code 1 to force AI agents to update documentation before proceeding.

KubeShark: A Kubernetes Skill for Claude Code and Codex to Catch Hallucinated YAML
KubeShark is a failure-mode-first Kubernetes skill for Claude Code and Codex that catches deprecated APIs, misconfigured probes, broken selectors, and other common AI-generated mistakes before they hit production.