If you'd rather skip everything below, the CLI walks through it. `aig init` prompts for a key, writes it to .env, and scaffolds a working starter file in TypeScript, JavaScript, or Python — whichever your project already uses.
npx aigateway-cli init # or install globally npm i -g aigateway-cli && aig init
One click with GitHub or Google. Your first test key lands in your clipboard. No card required.
# .env AIGATEWAY_API_KEY=sk-aig-...
Change one line — base_url. Every OpenAI SDK, every language, every framework, every agent.
from openai import OpenAI
client = OpenAI(
api_key=os.environ["AIGATEWAY_API_KEY"],
base_url="https://api.aigateway.sh/v1",
)
resp = client.chat.completions.create(
model="anthropic/claude-opus-4.7",
messages=[{"role": "user", "content": "hello"}],
)Same shape for text, images, audio, embeddings. Change the slug, nothing else.
# image
client.images.generate(model="black-forest-labs/flux-2-klein-9b", prompt="...")
# stt
client.audio.transcriptions.create(model="deepgram/nova-3", file=open("a.mp3","rb"))
# tts
client.audio.speech.create(model="deepgram/aura-2-en", voice="asteria", input="...")
# embeddings
client.embeddings.create(model="baai/bge-m3", input="hello")A capable coding agent reads one of these and can call every modality without a human editing config.
Everything below is optional on day one — turn each on when the problem it solves actually hurts.