Quickstart
Kloria exposes an API compatible with the OpenAI and Anthropic formats. There is nothing specific to install: your current SDKs and tools work, you only change the API address and the key.
OpenAI format
https://api.kloria.dev/v1Anthropic format
https://api.kloria.devIn three steps
Section titled “In three steps”-
Sign in to the console
Kloria is in invite-only beta. Once you have your invitation, sign in at app.kloria.dev. That’s where you manage your keys, balance and logs.
-
Create an API key
In the console, open API Keys then Create API Key. Give it a name that says where it’s used (
claude-code-laptop,invoice-script…), then copy it.The settings worth a look when creating it:
- Expiration Time: keep “Never expires” for personal use, set a date for a borrowed or temporary key.
- Quota: a per-key cap limits the damage if the key leaks or a script loops. Set one on any key you don’t watch daily.
- Model Limits and IP Whitelist: optional, to restrict a key to some models or some addresses.
A key looks like
sk-…. Treat it like a password: never in a Git repository, never in a message.Labels in this guide are the console’s English ones; if your console shows another language, the menus are in the same place.
-
Make a first call
Put your key in an environment variable, then run the request below. A JSON response with a
choicesfield means everything works.Fenêtre de terminal # read -s keeps the key off the screen and out of your historyread -s KLORIA_API_KEY && export KLORIA_API_KEYcurl https://api.kloria.dev/v1/chat/completions \-H "Authorization: Bearer $KLORIA_API_KEY" \-H "Content-Type: application/json" \-d '{"model": "claude-sonnet-5","messages": [{"role": "user", "content": "Say hello in one sentence."}]}'Fenêtre de terminal # Masked input, the key doesn't stay in your history$s = Read-Host "Kloria key" -AsSecureString$env:KLORIA_API_KEY = [System.Net.NetworkCredential]::new("", $s).Password$body = @{model = "claude-sonnet-5"messages = @(@{ role = "user"; content = "Say hello in one sentence." })} | ConvertTo-Json -Depth 5Invoke-RestMethod -Method Post -Uri "https://api.kloria.dev/v1/chat/completions" `-Headers @{ Authorization = "Bearer $env:KLORIA_API_KEY" } `-ContentType "application/json" -Body $body
What’s next
Section titled “What’s next”The model name is the only parameter that changes from one model to another. The full list and pricing are on Models and pricing.