Skip to content

Quickstart

Create an API key from the Dashboard, then call Chat completions from your backend.

Prerequisites

  • A Rikaii account — Sign up, then open the Dashboard
  • curl or any HTTP client that can send JSON and Authorization headers

1. Create an API key

  1. In the Dashboard, go to API keys.
  2. Create a key and store it in a secret manager or environment variable—it may only be shown once.

Use Authorization: Bearer <your-api-key> on every request.

2. Send a chat completion

Replace YOUR_API_KEY with your key. Production API host:

bash
curl -sS "https://api.rikaii.com/v1/chat/completions" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-4o-mini",
    "messages": [{"role": "user", "content": "Say hello in one sentence."}],
    "max_tokens": 64
  }'

A 200 response returns an OpenAI-shaped JSON body with choices, usage, and id.

Rikaii API documentation