2027 product guide · Evidence checked 20 November 2026

AI gateway in 2027: routing, failover and cost control

An AI gateway, also called an LLM gateway, is the control point between your application and one or more model providers. This page explains what it does, how it differs from a router, and where a single-vendor OpenAI-compatible endpoint is the simpler choice.

Short answer. An AI gateway puts one OpenAI-compatible endpoint in front of multiple model providers and adds routing, fallbacks, keys, budgets, caching and logs. A router picks a model; a gateway manages the traffic around it. Plugsky exposes 39 public models behind one endpoint and adds OpenAI-compatible migration without a rewrite.

What an AI gateway actually does

An AI gateway is infrastructure, not a model. Your application calls one endpoint; the gateway authenticates the request, applies policy, chooses an upstream provider or model, forwards the call, and returns a normalised response. It usually speaks the OpenAI Chat Completions shape, because that is the shape most SDKs already implement.

The useful part is the layer around the call. A gateway can hold provider credentials so keys never ship inside an app, enforce per-team spend or rate limits, retry a failed request, fall back to another model, cache repeated prompts, and write a log line that lets you reconstruct what happened. Those controls are the product. Model access is the commodity underneath.

“LLM gateway” and “AI gateway” are used interchangeably in the market. Some vendors narrow the term to text models, while others include images, embeddings, speech and video. Ask which modalities are covered before you assume the word means the same thing across vendors.

Gateway, router or proxy: the difference that changes the design

A router is a decision function. Given a prompt, a cost target or a latency target, it selects a model. A proxy is a forwarding layer: it takes a request and sends it upstream. A gateway is the superset that usually contains both, plus credentials, policy and telemetry.

The distinction matters during procurement because vendors price the same word differently. A router may be a feature inside a gateway, a library inside your application, or a standalone service. A proxy may be open source and self-hosted, or a managed endpoint. If you compare a router to a gateway on price alone, you are comparing different scopes of work.

The layers between an application and a model provider, and the job each one owns
LayerJobWhat it decidesFailure it prevents
SDK clientFormats requests and parses responsesRequest shape, streaming, retries in processApplication code breaking when a provider changes a field
RouterSelects a model for a requestCost, latency, quality or a fixed ruleEvery request going to the most expensive model
GatewayOwns the endpoint, keys, policy and telemetryAuthentication, budgets, fallback order, loggingKey sprawl and a provider outage taking the product down
Observability layerStores and analyses tracesRetention, sampling, alert thresholdsNobody noticing quality drift or a cost spike until invoicing

Most teams do not need all four layers on day one. A single product with one provider may need only the SDK and a stable endpoint. The gateway layer starts paying for itself when a second provider, a second team or a hard spend limit appears.

The four jobs buyers actually need

Unified access. One key and one request shape for several models removes per-provider SDK code and makes it possible to swap a model without a release. The hidden work is normalising parameters: tool calling, JSON mode, streaming chunks and usage fields are similar across providers but rarely identical.

Failover. A gateway can retry a 429 or a 5xx on a second model. That only helps if the fallback model accepts the same prompt shape and produces acceptable output. Test the fallback path with real prompts; an untested fallback is a second outage with extra steps.

Cost control. Budgets, per-key limits and model allow-lists stop one team or one bug from consuming the quarter’s spend. Usage attribution matters as much as the cap: without per-project tags, a shared gateway key makes cost allocation a guess.

Governance and evidence. Central logs give security and procurement a single place to inspect retention, access and subprocessors. That is useful during review, but a gateway does not create compliance by itself. The contract, the data-flow diagram and the provider’s attestations still carry the claim.

Deployment model decides more than the feature list

Gateways come in four practical shapes. The shape determines who is on call, where prompts and logs live, and how hard it is to leave. Feature checklists tend to look similar across shapes, so start with deployment and work backwards.

Four gateway shapes, who operates them, and the trade-off each one makes
ShapeExamplesWho operates itBest fitMain limitation
Managed multi-provider gatewayPortkey, OpenRouterThe vendorTeams that want many providers without running gateway infrastructureAdds a vendor and a data path; pricing and limits vary by plan
Self-hosted proxyLiteLLMYour platform teamTeams that must keep request traffic inside their own networkYou own upgrades, high availability and on-call
Edge or cloud gatewayCloudflare AI Gateway, Vercel AI Gateway, Kong AI GatewayThe platform vendor, close to your applicationTeams already standardised on that cloud or edge platformTied to that platform’s model access, policy surface and commercial terms
Single-vendor model APIPlugskyThe model vendorTeams that want one contract, one catalogue and private deploymentNot a bring-your-own-key router across unrelated providers

Examples are named to make the categories concrete, not to rank them. Each vendor publishes its own deployment, feature and pricing pages; those pages, not this table, are the authority on what a specific plan includes.

What to check before you choose

  1. Provider and model coverage. Count the models you will actually use, not the logo wall. Confirm the exact public IDs, context windows and output ceilings, and whether a deprecated ID silently maps to a different engine.
  2. Deployment and data path. Establish where the gateway runs, where logs and caches are stored, and which subprocessors see the prompt. A gateway hosted in one region can still call a model in another.
  3. Fallback behaviour. Ask what triggers a retry, how many times, which model receives the request, and whether the response tells you a fallback happened. Silent fallback can hide a quality problem.
  4. Key and budget controls. Look for per-project keys, spend caps, model allow-lists and a way to revoke access without redeploying the application.
  5. Compatibility surface. Test streaming, tool calling, JSON mode, embeddings and usage fields with your own SDK version. “OpenAI-compatible” is a spectrum, not a certification.
  6. Observability and retention. Confirm what is logged, how long it is kept, who can read it, and whether prompt logging can be disabled for sensitive workloads.
  7. Commercial terms. Check the pricing model, overage behaviour, minimum commit, notice period, SLA exclusions and the exit path for keys and logs.
  8. Failure demo. Ask for a live demonstration of a provider outage and a model schema change. A feature list does not show how the gateway behaves when the upstream misbehaves.

Where Plugsky fits

Plugsky is a single-vendor model API with an OpenAI-compatible endpoint at POST https://api.plugsky.com/v1/chat/completions. It is the right shape when the problem is “one contract, one catalogue, predictable plans and a private deployment path”, not “route across five unrelated providers with my own keys”.

The approved product facts are narrow and worth stating exactly. The catalogue has 39 public model IDs. Main text models serve a 262,144-token context. Plans run from Free at $0 and Hobby at $8/month through Starter at $20, Builder at $60 and Scale at $120; Builder and Scale have no monthly token cap and no per-token overage, subject to fair-use concurrency and RPM limits. Live regions are EU Frankfurt, GCC UAE, APAC Singapore and US Virginia, with Riyadh available on Enterprise only. Private VPC, on-premises and air-gapped deployment are contract-led, and the scope has to be confirmed in writing.

On trust, Plugsky describes SOC 2 as readiness rather than certification. Buyers should request the current report under NDA and confirm its scope and period. A gateway does not change that answer: it is still a vendor-review question about the entity that processes the data.

When Portkey is the better choice

Portkey is the better choice when the requirement is a managed control plane across several unrelated model providers, with guardrails, observability and virtual keys as first-class features, and when the team would rather buy that layer than operate it. It is also the more natural fit when procurement has already approved a multi-provider routing vendor and the remaining question is configuration, not architecture.

Plugsky is not a substitute for that scope. If you need bring-your-own-key access to Anthropic, Google and OpenAI behind one governance console, a multi-provider gateway is the correct category. Compare the two on data path and contract terms rather than on model count alone.

When LiteLLM or OpenRouter is the better choice

LiteLLM is the better choice when the gateway must run inside your own network, the platform team is willing to own upgrades and availability, and an open-source proxy with a self-hosted control plane is a better fit than another vendor relationship. The trade-off is operational: you inherit the on-call rota, the upgrade path and the security patching.

OpenRouter is the better choice when you want one key and a very broad model catalogue with minimal setup, and you accept that requests route through a third party. It suits experimentation and multi-model products where speed of access matters more than a single-vendor contract. It is a different data-path decision from a private deployment, and should be reviewed as one.

Neither comparison is a criticism. The honest question is which layer you want to own: the gateway, the model access, or both.

Migration path from a direct provider

A move to an OpenAI-compatible endpoint is usually a configuration change, not a rewrite. The work is in verification, not in the first request.

  1. Change the base URL and key. Point the official SDK at the new endpoint and keep the same request shape. Our OpenAI migration guide lists the exact fields.
  2. Map model IDs. Replace provider model names with Plugsky public IDs. Do not assume a familiar name maps to the same engine; check the catalogue.
  3. Run an evaluation set. Replay real prompts for tool calling, JSON output, long context and streaming. Compare outputs and latency on your own data, not on a vendor demo.
  4. Keep a rollback. Preserve the old base URL and keys until the evaluation passes, and route a small percentage of traffic first.

What we did not verify

  • We did not run latency, throughput, uptime or failover tests on Plugsky or any gateway vendor named on this page. No performance number here is a benchmark.
  • We did not reproduce competitor prices or plan limits. Pricing models and plan inclusions change, and the vendor’s own page is the authority.
  • We did not review a SOC 2 report, penetration test, subprocessor list or DPA for any vendor. Plugsky’s SOC 2 status is readiness; a report must be requested under NDA with its scope and period confirmed.
  • We did not confirm that every feature named in a vendor category is available on every plan, region or model.
  • We did not test how each gateway behaves during a real provider outage, or whether a fallback preserves tool-call semantics.
  • Riyadh availability is Enterprise-only according to Plugsky’s published facts; we did not verify contract terms for a specific buyer.

Frequently asked questions

What is the difference between an AI gateway and a router?

A router chooses which model handles a request. A gateway is the endpoint and control layer around that choice: it holds provider keys, applies budgets, retries or falls back, caches where supported, and records logs. Most gateways include a router; a router alone is not a gateway.

Does an AI gateway add latency?

Any extra network hop can add latency, and the amount depends on deployment, cache hit rate and retry behaviour. A gateway in the same region as your application adds less than a cross-region hop. We did not benchmark latency for this page, so treat vendor latency claims as unverified until you test your own workload.

Do I need a gateway if I use only one model provider?

Usually not for routing. A single-provider team may still want central keys, spend limits, logs and a stable endpoint that survives a model rename. If you already get those from your provider, a separate gateway adds a vendor without removing much work.

Is an AI gateway the same as an LLM proxy?

Close, but not identical. A proxy forwards requests; a gateway usually adds policy, routing, retries, budgets and observability. Vendors use the terms loosely, so check the feature list rather than the label.

Can an AI gateway help with data residency?

It can route requests to a region, but routing is not the same as residency. Residency depends on where inference runs, where logs and caches are stored, which subprocessors are involved, and what the contract says. Ask for the data-flow diagram and the region list in writing.

What should I check before choosing an AI gateway?

Check the providers and models covered, deployment options, failover behaviour, key and budget controls, log retention, data residency, supported SDKs, pricing model, and exit path. Ask for a live demo of a provider outage and a schema change, not just a feature list.

Related pages

One endpoint, one catalogue, one contract

Start on the free plan and test the migration path with your own prompts before moving to Builder or Scale.

Start Free → See pricing

Sources

Each vendor page below was checked on 20 November 2026 for the category description only. No competitor price, limit or benchmark is reproduced on this page.

Official pages used for this guide
SourcePage checkedChecked
Plugskyplugsky.com/pricing and plugsky.com/facts20 Nov 2026
Portkeyportkey.ai/docs20 Nov 2026
LiteLLMdocs.litellm.ai20 Nov 2026
OpenRouteropenrouter.ai/docs20 Nov 2026
Cloudflare AI Gatewaydevelopers.cloudflare.com/ai-gateway20 Nov 2026

Last checked 20 November 2026. Plugsky’s canonical plan numbers live at /pricing; this page explains the category and does not replace the plan terms.