Getting started
Sign in, create an API key from the dashboard, and point your existing SDK at our base URL. Keys begin with sk-lmh-.
# environment export OPENAI_API_KEY="sk-lmh-…" export OPENAI_BASE_URL="https://api.lmhaven.app/v1" # anthropic export ANTHROPIC_API_KEY="sk-lmh-…" export ANTHROPIC_BASE_URL="https://api.lmhaven.app/v1"
Authentication
Send your API key in the Authorization header. Every request is scoped to the key’s owning workspace; revoked keys return 401 immediately.
curl https://api.lmhaven.app/v1/chat/completions \
-H "Authorization: Bearer sk-lmh-…" \
-H "Content-Type: application/json" \
-d '{"model":"claude-opus-4-7","messages":[{"role":"user","content":"hi"}]}'Models
The full active roster, billed in the unit native to each modality. Ratios update weekly against each provider’s public list price.
| Model | Modality | Ratio |
|---|---|---|
| claude-opus-4-7 | Text | 28× tokens / $ |
| claude-sonnet-4-6 | Text | 32× tokens / $ |
| claude-haiku-4-5 | Text | 50× tokens / $ |
| gemini-3-1-pro | Text | 36× tokens / $ |
| gemini-3-flash | Text | 55× tokens / $ |
| seedream-5 | Image | 40× images / $ |
| novelai-v4 | Image | 45× images / $ |
| pixai-v4 | Image | 60× images / $ |
| nano-banana-pro | Image | 38× images / $ |
| elevenlabs-v3 | Voice | 22× minutes / $ |
Endpoints
Text — chat completions
POST /v1/chat/completions — OpenAI- and Anthropic-compatible body shape. Streaming via stream: true emits SSE chunks.
Image — generations
POST /v1/images/generations — pass model, prompt, size. Returns a signed URL valid for 24 hours.
Voice — text-to-speech
POST /v1/audio/speech — pass model, voice, input. Returns audio bytes inline.
Errors
Error responses follow a consistent envelope. Status codes mirror the underlying provider where possible.
| Code | Meaning |
|---|---|
| 400 | Malformed request body or disallowed parameter. |
| 401 | Missing or invalid API key. |
| 402 | Insufficient balance — top up from the dashboard. |
| 403 | Email not verified or feature not enabled for this workspace. |
| 429 | Rate limit exceeded. Backoff value is in Retry-After. |
| 5xx | Upstream provider failure. We retry once before surfacing. |
Rate limits
Default workspace limit is 600 requests / minute and 100 concurrent streaming connections. Limits scale with prepaid balance; contact support on Discord for higher tiers. The number you see is the number you get — we do not throttle behind the scenes or reroute to weaker checkpoints under load.
Webhooks & receipts
Top-up receipts and email-verification messages come from verify@lmhaven.dev. Webhook events for billing land in your dashboard Billing tab and are delivered as email receipts.
Need a hand?
Open the Discord — a real human replies in under an hour, 24/7. Never a chatbot.