The AI Proxy for Claude Code

PromptBus routes every Claude Code request to the cheapest capable model automatically. Simple questions use Haiku. Complex work stays on Sonnet. Savings add up without you noticing.

terminal
 ~ npx promptbus install
  ✓ Claude Code configured

 ~ promptbus start
  ✓ Proxy on :4701 · Dashboard :4702

  Start coding. Savings happen automatically.

How it works

PromptBus sits transparently between Claude Code and the API. Every request is classified and routed to the optimal model.

Claude CodeYour requestsPromptBusClassification & routingAPI ProviderAnthropic API
01

Claude Code sends request to PromptBus proxy

02

PromptBus classifies task and routes to best model

03

Request reaches cheapest capable model automatically

What's in PromptBus?

Everything you need to optimize AI costs, nothing you don't.

Zero Configuration

Install and start. PromptBus automatically intercepts Claude Code traffic with no config changes needed.

Installation guide

Safety-First Routing

Under 60% confidence? Request passes through unmodified. No downgrade means no quality loss, ever.

Architecture overview

Microsecond Overhead

Keyword-based classification adds zero measurable latency to your requests. No extra API calls needed.

How classification works

Custom Routing Rules

Configure routing rules via YAML or the dashboard UI. Per-project policies, effort levels, and confidence floors.

Configuration guide

Full Dashboard

Monitor routing decisions, track cost savings, edit rules, search logs, and export data from a local web UI.

Dashboard docs

Open Source, MIT

Audit the code, customize the rules, self-host. No accounts, no telemetry, no vendor lock-in. Free forever.

View on GitHub

Built for efficiency

Lightweight, local, and transparent.

7
Task types classified
~83%
Maximum cost savings
17+
Model variants supported
0
External dependencies

Dashboard

Real-time insights

Monitor routing decisions, track cost savings, and edit rules from a clean web interface at localhost:4702.

PromptBusLive
localhost:4702
1,247
Total Requests
843
Downgraded
67%
Reroute Rate
$12.42
Cost Saved
TimeTypeRequestedRouted ToEffortActionLatency
12:34:56read explainsonnet-5haiku-4-5Low↓ Rerouted1.2s
12:35:12small editsonnet-5sonnet-5Medium→ Passthrough3.4s
12:35:45debug loopsonnet-5sonnet-5High→ Passthrough8.1s
12:36:20test generationsonnet-5sonnet-5Medium→ Passthrough5.7s
12:36:58read explainsonnet-5haiku-4-5Low↓ Rerouted0.9s
12:37:30multi file refactorsonnet-5sonnet-5High→ Passthrough12.3s
1,247 total requests · Open full dashboard →

Get started in seconds

Three commands and you're saving money on every request.

01

Install

npx promptbus install

One command installs the proxy and configures Claude Code to route through it automatically.

02

Start

promptbus start

The proxy runs locally on port 4701. The dashboard is available at localhost:4702.

03

Ship

# Keep coding as usual

Every request is classified and routed to the optimal model. No workflow changes needed.

Start saving today

Free. Open source. No account required. Install PromptBus in under a minute and optimize your API costs automatically.