Kaeso is an open-source, self-runnable AI gateway designed to let applications communicate with multiple model providers through a single unified API while giving users full control over provider keys, routing, and usage.
Purpose: Kaeso sits between applications and model providers as a single entry point. Applications keep their existing SDKs (such as OpenAI, Anthropic, Google SDK); they only need to change two settings—the base URL and the key—to call the 41 chat providers it supports through Kaeso. Kaeso initiates calls in each provider's own format.
Key capabilities:
- Key management: Provider keys are encrypted using AES-256-GCM, with the master key held by the user; applications receive Kaeso keys, which are stored only as hashes.
- Budgets and rate limits: Budgets and rate limits can be set by project, member, service account, and key. Hard budgets reject requests before calling the provider, while soft budgets send alerts.
- Request logs: Every request records the key, member, model, token counts, latency, and cost calculated at the price at that time.
- Routing: Select models via aliases, with fallback when a provider fails, conditional routing based on headers/format/tokens, and weighted splitting.
- Console: Provides organizations, projects, keys, limits, routing, request logs, and playground, running alongside the gateway.
- Authentication: Single sign-on per organization through its own OpenID Connect provider, with two-factor authentication and roles.
- MCP portal: Each project can have its own MCP server portal; changes to tool definitions require administrator confirmation.
Usage: Kaeso is a Rust process that sits between applications and all providers. Each request goes through eight checks in a fixed order: key verification (determines the project and actor), decode request body (reads in the application's format and rejects anything Kaeso will not forward), model resolution (resolves aliases and their fallbacks in the project catalog), limit check (checks all rate and budgets for the key, member, and project simultaneously), obtain provider key (decrypts the AES-256-GCM-encrypted key using the user's master key), encode and send (converts to provider format and sends), reply conversion (decodes and converts back to application format; streaming responses are processed event by event), logging (after the reply is sent, records usage, cost, and request log).
Deployment: Can run Caddy, gateway, console, PostgreSQL, ClickHo via Docker Composeuse and Valkey; or use templates for Render, Railway, DigitalOcean, Fly.io, AWS, Azure, Google Cloud, Coolify, Dokploy, CapRover; or use the Kubernetes Helm chart.
Applicable scenarios: teams or organizations that need unified management of access to multiple AI providers, control of key security, enforcement of budgets and rate limits, and recording of detailed usage and costs.
Limitations: the materials do not provide specific system requirements, a complete list of supported providers, or limitation descriptions beyond performance data.