OpenAI-compatible API gateway

Never expose your AI API keys in code again.

Mux API sits between your app and your AI providers. Ship virtual keys to clients, keep the real ones locked away.

Read the docs
request.sh
# your app only ever sees the virtual key
curl https://api.muxapi.dev/v1/… \
  -H "Bearer kc_live_8f3a…"
What Mux API does
  • Authenticates virtual key
  • Checks limits — 42 / 60 rpm
  • Routes — primary 503 → fallback key
  • Logs — 200 · 412 tokens · 840 ms

Route to

OpenAI · Anthropic · Google Gemini · Groq · Together · any OpenAI-compatible API

Features

Everything between your app and the model.

Virtual keys

Hand your apps a revocable virtual key. A leaked client key is a one-click fix.

Fallback routing

If a provider errors, traffic moves to the next route automatically.

Rate limits and quotas

Cap requests and tokens per key before they become a surprise invoice.

Usage and request logs

Requests, tokens and errors per key, with the caller IP on every line.

How it works

Three steps, two lines of code.

01

Add your real keys

Paste provider keys once. They are encrypted and never shown again.

02

Create a virtual key

Set limits, pick routes and fallbacks. Shown once.

03

Point your app at the gateway

Swap the base URL. That is the whole migration.

Pricing

Simple pricing.

Trial

Try Mux API

Free

  • 100 lifetime requests
  • 10 RPM
  • 7-day logs
  • All features included
Start free

Starter

For side projects

$3 /mo

  • 10,000 requests / month
  • 30 RPM
  • 30-day logs
  • All features included
Choose plan

Most popular

Pro

For production apps

$5 /mo

  • 20,000 requests / month
  • 60 RPM
  • 60-day logs
  • All features included
Choose plan

Scale

For growing traffic

$10 /mo

  • 50,000 requests / month
  • 120 RPM
  • 90-day logs
  • All features included
Choose plan

Need more than 50,000 requests per month? Contact us for Enterprise.

Stop shipping secrets.

Create your first virtual key in under two minutes.