Let’s make your first request.
Connect a provider, configure your client, and send a request through Lunar.
Quickstart
- 1
Connect a provider
Add your API key in the console, or use your own deployment.
- 2
Update your base URL
Keep your SDK. Set your Lunar endpoint and API key.
- 3
Make a call. See the whole picture.
Your requests, costs, and latency appear together in Lunar.
import os
from openai import OpenAI
client = 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, Lunar!"}],
)
print(response.choices[0].message.content)
Use the endpoint and key from your Lunar workspace.
Getting Started
Install Lunar, set up your first route, and send your first request.
Models & Providers
See all 13 providers and 300+ models. Learn how to add your own.
Routing Strategies
Load balancing, fallbacks, semantic routing, and cost-based routing.
Observability
ClickHouse traces, cost tracking, latency monitoring, and dashboards.
Evaluations
Run model comparisons, use AI-as-judge, and track quality over time.
Self-Hosting
Deploy the full stack with Docker. ClickHouse, Go engine, Python API, and UI.