Documentation
The gateway is compatible with OpenAI and Anthropic SDKs. Replace base_url and the key - no other code changes are needed.
Base URL
https://api.llmka.dev/v1
Authorization
Authorization: Bearer $LLMKA_API_KEY
Response format
OpenAI Chat Completions / SSE
123456789101112
curl https://api.llmka.dev/v1/chat/completions \
-H "Authorization: Bearer $LLMKA_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "deepseek-v4.1-flash",
"messages": [
{"role": "system", "content": "You are a helpful assistant."},
{"role": "user", "content": "Hello!"}
],
"temperature": 0.7,
"stream": false
}'Reference
Main endpoints
| Method | Path | Purpose |
|---|---|---|
| POST | /v1/chat/completions | Chat generation. The stream: true flag turns on incremental output. |
| POST | /v1/completions | Classic text completion for older SDKs. |
| POST | /v1/embeddings | Vector representations of text for search and RAG. |
| POST | /v1/images/generations | Image generation for the models that support it. |
| POST | /v1/audio/speech | Text-to-speech: returns an audio file for the voice models of the catalog. |
| POST | /v1/audio/transcriptions | Speech-to-text: multipart upload of an audio file, returns the transcript. |
| GET | /v1/models | List of available models with their identifiers. |
Integrations
Connect editors and agents
Cursor
Settings → Models → OpenAI API Key: paste the key and set Override OpenAI Base URL to https://api.llmka.dev/v1.
Continue (VS Code / JetBrains)
In config.json add a provider with apiBase: "https://api.llmka.dev/v1" and your API key.
Cline / Roo Code
Pick OpenAI Compatible, then set Base URL and the key. Use a model id from /v1/models.
LangChain / LlamaIndex
Any OpenAI-compatible class accepts base_url - use it without touching the rest of your code.
n8n / Make
HTTP Request node: POST to /v1/chat/completions with the Authorization header.
Telegram bots
A proxy service talks to the gateway as it would to the regular OpenAI API, from your own infrastructure.
Errors
Response codes and actions
| Code | Reason | Action |
|---|---|---|
| 401 | The key is wrong or revoked | Check the Authorization header and the key status in the dashboard. |
| 402 | Not enough balance | Top up in the Billing section. |
| 403 | Client is paused or not approved | Contact support: the client status is set in the dashboard. |
| 404 | Model not found | Take the exact identifier from GET /v1/models. |
| 429 | Rate limit exceeded | Slow down or contact support to raise the limit. |
| 503 | Gateway temporarily out of capacity | Retry in a few minutes; if it repeats, contact support. |
| 5xx | Provider-side error | Retry the request; for outages see the Status page. |