Skip to main content

Configure an Upstream

Tasks

Add an upstream provider so AIControls can route developer requests to it. For how upstream routing works conceptually, see Upstreams.

  1. Go to Settings → Upstreams → Add upstream and select Anthropic.
  2. Fill in the upstream fields:

    FieldValue
    NameAny label, e.g. anthropic-prod
    API KeyYour sk-ant-... key from console.anthropic.com
    URLLeave blank for Anthropic's own API. Point it at a third-party gateway instead to use a service that speaks the same Anthropic Messages wire format (e.g. z.ai's GLM models) — the API key can then be in that gateway's own format instead of sk-ant-...
    ModelsLeave blank to allow all, or restrict to specific model IDs
note

AIControls supports all Claude models including claude-opus-4-8, claude-sonnet-4-6, and claude-haiku-4-5. New models appear automatically as Anthropic releases them.

note

The sk-ant-... key format is only enforced when the URL is left blank or points at Anthropic's own API (api.anthropic.com). A custom URL accepts whatever key format that gateway issues.

warning

Upstream names must be unique — adding an upstream with a name that already exists is rejected so an existing upstream is never overwritten by mistake.

When you configure more than one upstream for the same provider, give each a distinguishing scope — a different Priority, or a Model Patterns / Identity Source match — so AIControls knows which one to route each request to. Two enabled same-provider upstreams with the same priority and no distinguishing scope are ambiguous, and requests that either could serve are denied with an ambiguous-routing error. The Add/Edit form warns you before you save such a pair.

Configure a pool for failover

Preview

Upstream pools are a preview feature — see Upstream pools for how membership and failover are decided.

  1. Configure the upstreams you want as pool members first (see the provider steps above) — a pool references existing upstreams by name, it doesn't hold its own connection details.
  2. Go to Settings → Upstreams, switch to the Pools tab, and select Add Pool.
  3. Fill in the pool fields:

    FieldValue
    NameAny label, e.g. prod-anthropic
    Model PatternsGlob(s) controlling which requests route to this pool, e.g. claude-* — leave empty to match any model
    OIDC groupsLeave empty to match every caller
    PriorityTie-break order against other pools/upstreams with equal specificity — leave at 0 unless you need explicit ordering
  4. Add members in the order you want them tried. For each member:

    • Pick the upstream from the dropdown.
    • Watch the compatibility indicator — a member whose wire format conflicts with (or is ambiguous relative to) the members above it is flagged, and an Azure OpenAI / Azure AI Foundry member additionally needs its wire format set explicitly before it's included.
    • Check Fallback only if this member should never be tried first, regardless of its position in the list.

    Use the arrow buttons to reorder members, or the ✕ button to remove one — a pool needs at least one member.

  5. Save. If any member was excluded for a wire-format conflict, the save still succeeds but names the excluded member so you can fix it.
note

An upstream referenced by a pool is routed through the pool's Model Patterns / OIDC groups / Priority from then on — its own routing settings (if any) are ignored while it's a member. Removing it from the pool restores its own routing.

See also

For how AIControls picks between multiple configured upstreams, see Upstreams.