Quickstart

1. Create a platform key on the API Keys page. 2. Point anything below at the gateway. One model — juvat-1 — with -fast, -auto, and -max modes.

curl

curl https://www.juvat.app/api/v1/chat/completions \
  -H "Authorization: Bearer $JUVAT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "juvat-1", "messages": [{"role": "user", "content": "Hello"}]}'

juvat CLI

npm exec juvat login --key fg_...        # or: node apps/cli/dist/cli.js
juvat chat "explain this error" --mode fast
juvat setup opencode --write             # wire up the OpenCode coding agent

OpenCode (~/.config/opencode/opencode.json)

{
  "$schema": "https://opencode.ai/config.json",
  "provider": {
    "juvat": {
      "npm": "@ai-sdk/openai-compatible",
      "name": "Juvat",
      "options": {
        "baseURL": "https://www.juvat.app/api/v1",
        "apiKey": "{env:JUVAT_API_KEY}"
      },
      "models": {
        "juvat-1": {
          "name": "juvat-1"
        },
        "juvat-1-fast": {
          "name": "juvat-1-fast"
        },
        "juvat-1-auto": {
          "name": "juvat-1-auto"
        },
        "juvat-1-max": {
          "name": "juvat-1-max"
        }
      }
    }
  }
}

Continue (VS Code / JetBrains)

# Add under "models:" in ~/.continue/config.yaml
models:
  - name: juvat-1
    provider: openai
    model: juvat-1
    apiBase: https://www.juvat.app/api/v1
    apiKey: ${JUVAT_API_KEY}
    roles: [chat, edit, apply]
  - name: juvat-1-fast
    provider: openai
    model: juvat-1-fast
    apiBase: https://www.juvat.app/api/v1
    apiKey: ${JUVAT_API_KEY}
    roles: [chat, edit, apply]
  - name: juvat-1-auto
    provider: openai
    model: juvat-1-auto
    apiBase: https://www.juvat.app/api/v1
    apiKey: ${JUVAT_API_KEY}
    roles: [chat, edit, apply]
  - name: juvat-1-max
    provider: openai
    model: juvat-1-max
    apiBase: https://www.juvat.app/api/v1
    apiKey: ${JUVAT_API_KEY}
    roles: [chat, edit, apply]

Cline

Cline (VS Code) — Settings → API Provider:
  Provider:  OpenAI Compatible
  Base URL:  https://www.juvat.app/api/v1
  API Key:   your fg_ platform key
  Model ID:  juvat-1-auto  (or -fast / -max)

Cursor

Cursor — Settings → Models:
  1. Enable 'Override OpenAI Base URL'
     Base URL: https://www.juvat.app/api/v1
  2. OpenAI API Key: your fg_ platform key
  3. Add custom models: juvat-1, juvat-1-fast, juvat-1-auto, juvat-1-max

Errors follow the standard shape: 401 bad key · 402 balance/limit · 403 policy · 429 rate limit (respect Retry-After) · 503 paused. Responses include x-juvat-billed-cents and x-juvat-balance-cents on non-streaming requests.