Use case

Scale past one account's Claude API rate limit

Run Claude, GPT and Gemini at high concurrency on pooled capacity, with brief queueing, automatic failover and per-key limits that you set yourself.

Prepaid, no subscriptionREST or MCPOne key for models, data and agents
lovelyqueue · spreadpool Apool Bpool C429 → retrypool Dpool Epool F

One provider account tops out at its own rate limits, and an agent fleet or a batch job that needs real Claude API concurrency finds that ceiling fast. Lovely Router serves each model from a pool of channels, admits your traffic against their combined capacity, queues requests briefly when every channel is busy and retries a failed request on another channel. You keep your SDK and change the base URL; a retryable 429 or 502 reaches you only when a problem outlasts all of that.

01

How it works

010203
  1. Requests spread across a pool

    Each channel group (claude-value, gpt-value, gemini-value) pools capacity from several channels, and new conversations are spread across them. A channel that returns more errors, or answers much more slowly than usual, gets a smaller share until it recovers; one that keeps failing is taken out of rotation for a while.

  2. Bursts wait instead of failing

    When a channel is full, the gateway tries the others that serve the model. When all are full, the request queues for the one expected to free up first, for at most 10 seconds. An admitted request carries x-lovely-queued-ms with the time it waited.

  3. Failures are retried for you

    A request whose channel times out, returns 429 or a 5xx, or fails before the first token of a stream is retried on another channel, up to three attempts. Streams are held until the first token (at most 15 seconds), so an early failure never reaches you as a broken stream.

02

What reaches your client

search_toolsrun_toolget_run
StatusWhenWhat to do
429Your key's requests-per-minute or concurrency limit, after waiting up to 2 seconds for room. Has retry-after.Wait retry-after seconds, or raise the key's limits.
429All capacity for the model was busy for 10 seconds. Has retry-after.Wait retry-after seconds and retry.
429Every channel tried reported a rate limit.Retry with backoff.
502Every channel tried failed.Retry with backoff.
402Your balance is at or below zero, or the key reached its spend limit.Top up or raise the limit. Don't retry.
400, 404, 413, 422The request itself is invalid. Never retried elsewhere.Fix the request.

A request rejected with 429 is not charged. Error bodies follow your API format.

03

Retry the rest in your client

search_toolsrun_toolget_run

A 429 or 502 means the problem lasted through several attempts already. Retry a few more times with exponential backoff and jitter, and honor retry-after. The Anthropic and OpenAI SDKs retry twice by default; raise it for batch jobs:

# --retry covers 429 and 5xx and honors retry-after
curl --retry 5 --retry-max-time 120 https://lovelyrouter.com/v1/chat/completions \
  -H "Authorization: Bearer $LOVELY_API_KEY" \
  -H "content-type: application/json" \
  -d '{"model": "gpt-6.1-sol", "messages": [{"role": "user", "content": "Hi"}]}'

For streams, retry only when the error arrives before any content: once tokens flow, a failure arrives as an error event inside the stream.

04

Limits you set on each key

Every key can have a requests per minute limit (rolling 60 seconds) and a max concurrent requests limit (open streams count until they end). Both are off by default. Use separate keys with their own limits so a batch job can't starve production. Keys also take a spend limit, a model allow-list and an expiry date; see API keys.

05

Prompt caches survive the load

Each conversation is pinned to the channel that holds its prompt cache, and part of every pool is kept for pinned turns, so running sessions keep cache prices at peak. When a pinned channel is full, the turn waits for it briefly (about a second for short prompts, up to ten for long ones) before it moves and writes a new cache. See Prompt caching.

06

Choose a channel group, or let Auto pick

Keys default to Auto, which sends each request to the best available group for its model; a retry may use any group that serves it. Bind a key to one group, or send the x-lovely-group header, and every retry stays inside that group, so the price never changes behind your back. Responses name the group and channel that served them. See Channel groups.

07

Watch capacity live

The status page shows each channel group's availability hour by hour over the last 24 hours, refreshed every minute. The model list shows every model with its live availability.

08

Patterns for high-concurrency apps

Batch jobs and evals

Raise the SDK's retries to five, and give the job its own key with a concurrency limit so it never crowds out production.

Agent fleets with long streams

Allow at least 30 seconds before the response starts: a request may wait for capacity, and streams start with their first token.

Apps that summarize history

Send x-session-id with a stable id per conversation, so turns keep hitting their cache.

09

What you pay

A call is billed per token (input, output, cache reads and cache writes) at the model's list price times the multiplier of the group that served it. With every live group at ×1.00 today, you pay list price. Queued requests are not charged until they run, and requests rejected with 429 or failing with an error cost nothing. A stream you cancel is charged for what was produced. Everything comes from a prepaid balance with no subscription; see pricing.

ModelContextInputOutputCache read
Claude Fable 5.1
claude-fable-5.1
1M$10.00$50.00$0.25
Claude Opus 5.5
claude-opus-5.5
1M$4.00$20.00$0.20
Claude Sonnet 5.5
claude-sonnet-5.5
1M$2.00$10.00$0.10
Claude Haiku 5.5
claude-haiku-5.5
1M$0.10$0.50$0.01
Claude Fable 5
claude-fable-5
1M$10.00$50.00$1.00
Claude Opus 5
claude-opus-5
1M$5.00$25.00$0.50
Claude Sonnet 5
claude-sonnet-5
1M$2.00$10.00$0.20
Claude Opus 4.8
claude-opus-4.8
1M$5.00$25.00$0.50
Claude Opus 4.7
claude-opus-4.7
1M$5.00$25.00$0.50
Claude Opus 4.6
claude-opus-4.6
1M$5.00$25.00$0.50
Claude Sonnet 4.6
claude-sonnet-4.6
1M$3.00$15.00$0.30
Claude Opus 4.5
claude-opus-4.5
200K$5.00$25.00$0.50
Claude Sonnet 4.5
claude-sonnet-4.5
1M$3.00$15.00$0.30
Claude Haiku 4.5
claude-haiku-4.5
200K$1.00$5.00$0.10

USD per 1M tokens, live from the catalog.

10

Frequently asked questions

?
Does Lovely Router remove Claude API rate limits?+

It removes the ceiling of a single account: each model is served from capacity pooled across several channels, and your requests are admitted against their combined capacity. Capacity is still finite, so when every channel serving a model stays full for 10 seconds, the request fails with 429 and a retry-after header.

What happens when a channel fails during a request?+

The gateway retries the request on another channel in the same group, up to three attempts, which is LLM API failover without code of your own. For streams this happens only before the first token; after that, a failure arrives as an error event inside the stream.

Am I charged for queued or rate-limited requests?+

No. A queued request isn't charged until it runs, and a request rejected with 429 isn't charged at all. Requests that fail with an error aren't charged either.

Can I set my own rate limits per API key?+

Yes. Each key can have a requests-per-minute limit and a max-concurrent-requests limit, both off by default. A request over the limit waits up to 2 seconds for room, then fails with 429 and a retry-after header.

Does failover change the price I pay?+

Not when your key is bound to a channel group or you send the x-lovely-group header: every retry stays inside that group. With Auto and no header, a retry may use another group, and the response header always reports the one that answered.

Running coding agents at scale? See AI coding agents and the Claude API page. The rate limits docs have the full retry guide.

One prepaid key for models, data and agents

No subscription. Top up, use what you need, see every charge in your logs.