API reference
export LUMOSWITCH_BASE_URL="https://api.lumoswitch.com/v1"
export LUMOSWITCH_API_KEY="the access key shown once at creation"OpenAI requests use Authorization: Bearer $LUMOSWITCH_API_KEY. Configurations may additionally enable unified Anthropic Messages and Gemini generateContent routes; see Protocols and compatibility. The same access key, model allowlist, limits, and accounting apply to every enabled format.
curl "$LUMOSWITCH_BASE_URL/chat/completions" \
-H "Authorization: Bearer $LUMOSWITCH_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"your-client-facing-model-name","messages":[{"role":"user","content":"Say hello."}]}'stream: true uses Server-Sent Events. With failover, every candidate must support the requested tools, vision, structured output, embeddings, or other model capability.
| HTTP | Meaning |
|---|---|
| 400 | Invalid request for the selected format |
| 401 | Missing, invalid, revoked, or blocked key |
| 403 | Model or policy denied |
| 404 | Unknown client-facing model name or route |
| 408 | Request timed out |
| 413 | Request body exceeds the route limit |
| 415 | MIME type is not allowed for the route |
| 422 | Request could not be processed |
| 429 | Key, team, or provider limit reached |
| 5xx | Lumoswitch Runtime or provider unavailable |
Local models
Connect Ollama or LM Studio to Lumoswitch with a reachable Base URL. Check host and container networking, discover models, and troubleshoot connection failures.
Security and data handling
Understand Lumoswitch credential storage, request data, usage records, and network boundaries. Protect local client settings, apply least privilege, and rotate keys.