Shapes the gateway accepts
Only these exact paths exist; a near miss such as
/v2/chat/completions is a
404, not a guess.
X-AG-API-Key, x-api-key, x-goog-api-key, or
Authorization: Bearer, which is what lets stock SDKs point at the gateway
unchanged. Copy the exact form
from the application’s Connect tab; it already reflects the strategy and the
deployment.
The model field
model is where the client meets routing:
auto hands the choice to the gateway, a short name resolves to the first
registry that serves it, @provider/model prefers a provider. Gemini puts the
model in the path rather than the body; the rule is the same.
Model restrictions on the application apply before any provider is called. The
response carries X-Selected-Provider and X-Selected-Model, which is the first
thing to read when a request went somewhere you did not expect.
What translation costs you
Because the dialect and the provider can differ, the gateway normalises a few things once it knows which model it is talking to:
The last row is the honest limit of translation: fields that exist in one
provider’s API and nowhere else cannot be carried across. Everything in the
common core — messages, tools with names, temperature, streaming — is.
Streaming
Set"stream": true on OpenAI, Anthropic, Cohere and Responses; on Gemini call
:streamGenerateContent or add ?alt=sse. Events are re-encoded to the client’s
format.
If an upstream stream dies after the response has started, the HTTP status is
already 200 and cannot change. The gateway emits a final error event in the
client’s format instead — upstream_error for OpenAI-shaped clients, an
event: error for Anthropic, an error object for Gemini — so a client that
handles errors mid-stream sees one, and one that does not sees a truncated
response rather than a hang.