Switching from Portkey

Portkey alternative.
One endpoint. Every modality. Half the config.

Portkey is a gateway-as-a-service focused on governance and observability. AIgateway bundles that with a broader model catalog (image, video, audio, voice beyond text) and a sub-account API for multi-tenant products.

Get your key →See pricingClaim credit match
Migration

One-line diff.

Change the base URL and the key. Every other line of your integration stays the same.

Before — Portkey
from portkey_ai import Portkey

client = Portkey(
    api_key="pk-...",
    virtual_key="openai-...",
)

r = client.chat.completions.create(
    model="gpt-5.4",
    messages=[{"role": "user", "content": "Hello"}],
)
After — AIgateway
# pip install aigateway-py openai
# aigateway-py: sub-accounts, evals, replays, jobs, webhook verify.
# openai SDK: chat/embeddings/images/audio — drop-in compat per our SDK's own guidance.
from openai import OpenAI

client = OpenAI(
    base_url="https://api.aigateway.sh/v1",
    api_key="sk-aig-...",
)

r = client.chat.completions.create(
    model="openai/gpt-5.4",
    messages=[{"role": "user", "content": "Hello"}],
)
Why switch

What AIgateway ships that Portkey doesn't.

WINS
  • 1150+ models across every modality, not 40 text-heavy.
  • No seats, no subscription — you pay for usage only.
  • Sub-account API mints end-user keys with spend caps and isolated analytics.
  • Eval-driven routing: upload a dataset, we pick the cheapest model that passes.
  • Cached requests get a 50% discount on the uncached cost (not 100%).
HONEST
What Portkey does better, per their public docs.
  • Portkey ships a Python SDK with richer prompt-management primitives out of the box; we publish equivalents on our Enterprise tier.
Credit match

Send your last Portkey invoice.
We match it.

Forward last month's Portkey invoice to switch@aigateway.sh and we apply matching AIgateway credit (up to $1,000) within 24 hours. Same base URL change. No migration tax.

Other migrations

Switching from something else?

Switch from OpenRouter →Switch from Helicone →Switch from LiteLLM →Switch from Together AI →Switch from Fireworks AI →Switch from Requesty →Switch from Braintrust →