Two years ago the question in most engineering organisations was which model should we use. Today the question is different, and it is not a model question at all: who is calling which model, with what data, on whose budget, and can we prove it. The AI Gateway is the piece of infrastructure that answers that question. This report explains where the category comes from, what it actually replaces, and how to tell whether your company needs one now or can wait.
Where the category comes from
The pattern is not new. Every time a scarce, expensive, externally provided capability spreads across teams, a control point appears in front of it. Databases got connection poolers. Third-party APIs got API gateways. Cloud spend got FinOps tooling. Model providers are following the same curve, only faster, because adoption did not go through procurement: it went through a developer pasting a key into an .env file.
By the time a platform team notices, the typical mid-size company has:
- Between five and fifteen provider keys spread across repositories, CI secrets and personal accounts.
- No single answer to "how much did we spend on inference last month, by team".
- At least one integration sending customer identifiers to a provider under a default data-retention policy nobody read.
- A compliance function that has started asking questions and is getting answers from memory.
The AI Gateway exists because those four problems share a solution: put one governed hop between every caller and every provider.
What an AI Gateway is
At its simplest, an AI Gateway is a reverse proxy that speaks the providers' APIs on one side and a single, stable API on the other. What makes it a governance layer rather than a convenience layer is what it does in the middle.
| Concern | What the gateway does | What it replaces |
|---|---|---|
| Access | Issues one key per project with scopes; holds provider keys itself | Keys copied between repos and people |
| Cost | Meters every call; enforces budgets per project and period | A spreadsheet reconciled against provider invoices |
| Data | Detects and masks identifiers before the request leaves your network | A policy document and good intentions |
| Audit | Logs who called what, when, with which policy outcome | Provider dashboards with no notion of your org chart |
| Resilience | Routes, retries and fails over across providers | Each team re-implementing the same retry loop |
A few properties follow from this and are worth spelling out, because they are where products differ most:
- Deployment location. A gateway that runs in your infrastructure can see request bodies and apply data policies to them. A gateway that runs as a SaaS in front of the provider cannot, without becoming another third party you need to assess.
- Policy as configuration, not as code. If a budget cap or a masking rule requires a deploy, the people who own the rule (finance, compliance) will never own it in practice.
- Provider neutrality. The gateway should make switching providers a configuration change for the caller. If it leaks provider-specific semantics through its API, it has become a wrapper, not a control point.
What an AI Gateway is not
The category is young and the name is being stretched. Three things are routinely sold as gateways and are not:
An SDK is not a gateway. A client library that standardises the call shape across providers is useful, but it runs in the caller's process. It cannot enforce anything the caller does not want enforced, and it cannot see traffic from callers who did not install it.
An observability tool is not a gateway. Tracing every prompt and completion is valuable, and a gateway is a good place to emit those traces from. But observing a cost overrun after the fact is not the same as stopping it at the edge.
A prompt-management platform is not a gateway. Versioning prompts and running evaluations is an application-layer concern. The gateway should be indifferent to what the prompt says, except where a policy applies to its contents.
A simple test: if you removed the product tomorrow, would any call that should be blocked still go through? If the answer is yes, it was never a control point.
When a company needs one
Not every company does, or not yet. The signal is not the volume of calls but the number of independent callers and the regulatory exposure of what they send. Three thresholds, from field experience:
Threshold 1: more than three teams calling providers directly
Below this, a shared library and a shared key with a monthly invoice review is tolerable. Above it, the coordination cost of keys, budgets and incidents grows faster than the teams do. This is the point where the platform team usually starts building an internal proxy. Building one is a reasonable choice; the trap is underestimating what it will need to do by month six.
Threshold 2: customer or employee data in prompts
The moment a prompt contains a name, an account number or a national identifier, the question "which provider saw it, under which terms" becomes a legal question. Answering it per integration does not scale. Answering it once, at the gateway, with a masking policy that knows what a DNI or an IBAN looks like, does.
Threshold 3: anyone asks for an audit trail
In regulated sectors this arrives as a DORA third-party-risk question, a GDPR data-processing inventory, or an internal audit finding. The request is always the same underneath: show me every call, who made it, and what controls applied. If the answer requires joining logs from six services, you are already late.
Questions a CTO should ask
Before standardising on a product (or on an internal build), these are the questions that separate a control layer from a convenience layer:
- Where does the gateway run, and can it see request bodies without sending them to a third party?
- Can a budget be set per project and per period, and what happens at the cap: a warning, a throttle, or a hard stop?
- Who can change a policy, and is the change itself logged?
- When a provider is down, what does the caller see, and who decided the fallback?
- What does the audit export look like, and can compliance read it without an engineer?
- What is the exit plan: if we stop using the gateway, what do callers have to change?
# The shape a project policy should take: owned by the project,
# readable by finance and compliance, enforced at the edge.
project: payments-copilot
budget:
period: month
limit_eur: 1200
on_exceed: block
data:
mask: [dni, iban, email]
block_on: [credit_card]
providers:
allowed: [openai, anthropic]
fallback: anthropic
Where this is going
The gateway will not stay a proxy. The same control point that meters cost and masks data is the natural place to govern tool calls from agents, to enforce which internal systems a model may reach, and to apply the same policies to MCP servers that today apply to HTTP APIs. Companies that establish the control point now will extend it. Companies that wait will be standardising three things at once, under audit pressure.
That is the practical argument for the category: not that it does anything a determined platform team could not build, but that it puts the control point in place before the next wave of integrations arrives without asking.