Skip to main content
A
Docs

Gateway

Anar Gateway routes AI requests to your own model providers. It applies keys, budgets, limits and routing rules, and records each request.

What the Gateway does

Anar Gateway is the single entry point for AI requests in your organisation. Anar products and your own applications send model requests to the Gateway. The Gateway sends each request to one of your model providers.

The Gateway does not supply models. You connect your own provider accounts. Read Bring your own models.

Who uses it

PersonTasks
Platform administratorConnects providers, creates virtual keys, sets budgets and routing rules
DeveloperSends model requests with a virtual key or a token
Finance or service ownerReads cost and usage by key, team, customer and model
AuditorReads the request log

Key concepts

ConceptMeaning
ProviderA model provider account that you connect, such as a cloud model provider or a model server in your network
Provider keyThe credential for a provider account. Each key lists the models it can call and has a weight.
Model nameThe name in the model field of a request. Use provider/model, or a bare model name that a provider key lists.
Virtual keyA key that the Gateway issues to a team or an application. It controls which providers and models the holder can use.
Team, customerGroups of virtual keys. Use them to report and limit usage together.
BudgetA spending limit in US dollars that resets on a schedule
Rate limitA limit on tokens or requests in a period
Routing ruleA condition and a target. When the condition matches, the Gateway sends the request to the target provider and model.
FallbackAnother provider and model to try when the first one fails
GuardrailA content check by Guard before the request goes to a provider. Guardrails are not available in this release.

Supported providers

The Gateway can send requests to the APIs of these provider types. You bring your own account for each provider.

OpenAI, Azure OpenAI, Anthropic, Amazon Bedrock, Google Vertex AI, Google Gemini, Mistral, Cohere, Cerebras, Perplexity, xAI, OpenRouter, Hugging Face, Nebius, Parasail, Replicate, ElevenLabs, Ollama and SGLang.

You can also connect a custom provider that uses the request format of one of these types.

What the Gateway records

  • Each request: time, model, provider, tokens, cost, latency, status and virtual key.
  • Audit events: configuration changes, key operations and refused requests.

Read Audit and records.

Limits of this release

  • The Gateway runs as one instance. It does not run as a cluster.
  • Roles for the Gateway administration API are set in the Gateway configuration. The console cannot change them.
  • The console does not show audit events yet.

Next steps