Unified Gateway
One OpenAI-compatible API that routes to 13 providers and 300+ models. Change one line of code to start.
import os
import openai
# Just change the base URL — everything else stays the same
client = openai.OpenAI(
base_url=os.environ["LUNAR_BASE_URL"],
api_key=os.environ["LUNAR_API_KEY"]
)
response = client.chat.completions.create(
model="openai/gpt-4o-mini",
messages=[{"role": "user", "content": "Hello!"}]
)
print(response.choices[0].message.content)- OpenAI-compatible API -- drop-in replacement, same SDK, same format
- 13 providers: OpenAI, Anthropic, Google Gemini, Mistral, Groq, DeepSeek, Perplexity, Cerebras, SambaNova, Together, Fireworks, Cohere, AWS Bedrock
- 300+ models with automatic per-token pricing baked in
- Full streaming support for all providers including Anthropic SSE translation
- Vision and multimodal support (base64 or URL images)
- Tool calling with cross-provider format translation