plaingateway
Features

Rate limits

What happens when a host rate limits a request.

The gateway sets no request rate limit of its own, and the dashboard shows none. Hosts have their own limits. When a host answers 429, the gateway tries the model's next eligible host. It also moves on after a timeout or a 5xx. When Allow fallbacks is off on /settings/preferences, the gateway tries one host per model and returns that host's error; see Account settings. You get 429 only when the last host tried also refused. Retry-After is passed through when that host sent it. A model with one host has no other host to try. Add fallback models with models (see Model fallbacks) to spread load.

The balance is the other limit. Each request reserves its largest possible cost before it starts, from max_tokens and the prompt size. Many large requests at once can get 402 even when the balance would cover their real cost. A lower max_tokens reserves less.

The rate_limit field in GET /auth/key is deprecated and means nothing.