What is an AI gateway?
In short
An AI gateway is a single entry point through which applications call artificial intelligence models. It centralises authentication, model choice, quotas, logging and usage rules, without tying each application to one provider. It is also called an LLM gateway or an LLM proxy.
The term spread as models and providers multiplied: one organisation often uses several models, local and cloud, and wants to govern them in one place.
Try the APIWhat an AI gateway does
- Authenticate the caller and enforce their rights.
- Pick the model: forced, routed by rules, or learned.
- Enforce quotas and track usage and cost.
- Log calls for audit and troubleshooting.
- Handle errors: timeouts, circuit breaker, fallback to another model.
- Keep provider keys on the server side, never in applications.
How it differs from an API gateway
A classic API gateway exposes, secures and monitors APIs without knowing their content. An AI gateway understands the calls: it counts tokens, picks a model, streams answers and applies AI-specific rules. The two are often combined: the API gateway at the edge, the AI gateway behind it.
Example: a request through AISIA
AISIA is a local-first AI gateway. An application that uses the OpenAI SDK only changes the base URL and the key, then calls /v1/chat/completions.
curl https://api.aisia.fr/v1/chat/completions \
-H "Authorization: Bearer $AISIA_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"auto","messages":[{"role":"user","content":"Hello"}]}'The gateway checks the key, applies the organisation's policy, tries a local model first, and reports in the response the model actually used.
Related terms
- LLM proxy: a common synonym, often used for a simpler gateway.
- Model orchestration: coordinating several models in one process.
- Local-first: the principle of running locally before turning to the cloud.
- MCP: the protocol an agent uses to call tools, including a gateway's tools.
Frequently asked questions
Are AI gateway, LLM gateway and LLM proxy the same thing?
In practice, yes: all three name a single entry point in front of models. Vendors give them a wider or narrower scope.
Does an AI gateway replace a model?
No. It organises access to models; it does not produce the answers itself.
Is an AI gateway useful for a single model?
Not necessarily. It becomes useful once several teams, several models or quota and traceability requirements come into play.
Can an AI gateway run without the cloud?
Yes, if the models are local. AISIA can be deployed in your datacenter, with no outbound network if the contract says so.