Skip to content
Qorinix QX / API DOCS
Sign in Create account

Developer API

Qorinix API documentation

An OpenAI-compatible chat completions API, paid for with prepaid credit.

Base URL https://qorinix.com/v1. Use it with the official OpenAI SDKs, or call it directly over HTTPS from your server.

Overview

The Qorinix API is OpenAI-compatible. It works with the official OpenAI SDKs: set the base URL and the API key, and keep the rest of your code.

Base URL
https://qorinix.com/v1
Authentication
Authorization: Bearer qx_live_…
Billing
Prepaid credit in US dollars. No subscription.
EndpointPurpose
POST /v1/chat/completionsCreate a chat completion, streamed or not.
GET /v1/modelsList the available models.
GET /v1/models/{id}Look up one model.

Quickstart

  1. Create an account, then add credit and create an API key at /account/api.
  2. Store the key in the QORINIX_API_KEY environment variable on your server.
  3. Send a request with curl or an OpenAI SDK.
curl
curl https://qorinix.com/v1/chat/completions \
  -H "Authorization: Bearer $QORINIX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "qorinix-3.1-instant",
    "messages": [{"role": "user", "content": "Say hello in five words."}],
    "max_tokens": 256
  }'
Python (openai)
import os
from openai import OpenAI

client = OpenAI(
    base_url="https://qorinix.com/v1",
    api_key=os.environ["QORINIX_API_KEY"],
)

response = client.chat.completions.create(
    model="qorinix-3.1-instant",
    messages=[{"role": "user", "content": "Say hello in five words."}],
    max_tokens=256,
)

print(response.choices[0].message.content)
print(response.usage)
Node.js (openai)
import OpenAI from "openai";

const client = new OpenAI({
  baseURL: "https://qorinix.com/v1",
  apiKey: process.env.QORINIX_API_KEY,
});

const response = await client.chat.completions.create({
  model: "qorinix-3.1-instant",
  messages: [{ role: "user", content: "Say hello in five words." }],
  max_tokens: 256,
});

console.log(response.choices[0].message.content);
console.log(response.usage);

Authentication

Send your key in the Authorization header of every request:

HTTP header
Authorization: Bearer qx_live_…
  • Keys are created at /account/api.
  • The full key is shown once, when it is created. Qorinix stores only a hash of it.
  • A key can be revoked at any time.

Keys are for servers. The API sends no CORS headers, so it cannot be called from browser JavaScript. Never ship a key in a web page or a mobile app.

Models and prices

Prices are in US dollars per 1 million tokens.

ModelInput, per 1M tokensOutput, per 1M tokensContext windowMax output
Qorinix 3.1 Instantqorinix-3.1-instantLowest time to first token. Chat, classification, extraction and anything interactive. US$0.25 US$1.00 131,072 tokens 8,192 tokens
Qorinix 3.2 Reasoningqorinix-3.2-reasoningStronger step-by-step answers at very high throughput. Analysis, coding and long outputs. US$1.00 US$3.00 131,072 tokens 8,192 tokens

The same list is available from the API:

curl
curl https://qorinix.com/v1/models \
  -H "Authorization: Bearer $QORINIX_API_KEY"

Billing and credit

The API is paid for with prepaid credit in US dollars, bought at /account/api. Preset amounts are US$10, US$20, US$50 and US$100; you can also enter any whole number of dollars from US$10 to US$500.

  • Credit is valid for 12 months from purchase.
  • No subscription is needed for the API, and membership plans do not include API credit.
  • Each request first reserves its maximum possible cost from your balance. The unused part is returned the moment the request finishes.
  • You are charged for the tokens the model reports.
  • If a request could cost more than the remaining balance, it is refused with HTTP 402 before any work is done. Lower max_tokens or add credit.
  • If you close a streaming connection early, you are charged for the prompt and for the text produced so far (estimated).
  • A request that fails on our side is not charged.

Chat completions

POST /v1/chat/completions accepts a JSON body with these fields.

FieldDetails
modelA model ID from the table above.
messagesUp to 256 messages. Roles: system, developer, user, assistant. Content is text: a string, or an array of {"type": "text"} parts.
max_tokens
max_completion_tokens
Default 1024. The maximum depends on the model. Values below 256 are raised to 256, because both models reason briefly before answering and that reasoning counts toward the limit and toward completion_tokens.
temperature0 to 2.
top_pSupported.
stopUp to 4 strings.
seedSupported.
streamSet to true for server-sent events. See Streaming.
stream_options.include_usageSet to true to receive a final usage chunk when streaming.

A short system line naming the model is added to every request. It is included in prompt_tokens.

Not supported yet

These return HTTP 400 with code unsupported_parameter or unsupported_content:

  • Tool and function calling.
  • Images, audio and files.
  • n greater than 1.
  • logprobs.
  • response_format other than text. Ask for JSON in the prompt instead.

Unknown extra fields are ignored.

Streaming

With "stream": true the response is a stream of server-sent events in the OpenAI chunk format. The stream ends with data: [DONE]. Set stream_options to {"include_usage": true} to receive a final chunk that carries the token usage.

curl
curl -N https://qorinix.com/v1/chat/completions \
  -H "Authorization: Bearer $QORINIX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "qorinix-3.1-instant",
    "messages": [{"role": "user", "content": "Write a haiku about speed."}],
    "stream": true,
    "stream_options": {"include_usage": true}
  }'
Python (openai)
stream = client.chat.completions.create(
    model="qorinix-3.1-instant",
    messages=[{"role": "user", "content": "Write a haiku about speed."}],
    stream=True,
    stream_options={"include_usage": True},
)

for chunk in stream:
    if chunk.choices and chunk.choices[0].delta.content:
        print(chunk.choices[0].delta.content, end="", flush=True)
    if chunk.usage:
        print()
        print(chunk.usage)
Node.js (openai)
const stream = await client.chat.completions.create({
  model: "qorinix-3.1-instant",
  messages: [{ role: "user", content: "Write a haiku about speed." }],
  stream: true,
  stream_options: { include_usage: true },
});

for await (const chunk of stream) {
  process.stdout.write(chunk.choices[0]?.delta?.content ?? "");
  if (chunk.usage) console.log("\n", chunk.usage);
}

The Python and Node.js examples reuse the client from the Quickstart.

Limits

  • 600 requests per minute per key.
  • Request body up to 1 MB.
  • Up to 256 messages per request.
  • A request is stopped after 120 seconds.

Errors

Errors use the OpenAI shape:

JSON
{
  "error": {
    "message": "...",
    "type": "...",
    "param": null,
    "code": "insufficient_credit"
  }
}
HTTP statusCodeWhat it means
400invalid_request_error
context_length_exceeded
unsupported_parameter
unsupported_content
The request is not valid, is too long for the model's context window, or uses something that is not supported yet. Change the request before retrying.
401missing_api_key
invalid_api_key
api_key_revoked
No key was sent, the key is not recognised, or the key has been revoked.
402insufficient_creditThe request could cost more than the remaining balance. Lower max_tokens or add credit.
404model_not_foundThe model ID does not exist.
413request_too_largeThe request body is larger than 1 MB.
415unsupported_media_typeThe request body was not sent as JSON.
429rate_limit_exceededToo many requests for this key. Wait for the time given in the Retry-After header, then retry.
502upstream_errorTemporary failure on our side. Safe to retry.
503overloaded
service_unavailable
Temporary failure on our side. Safe to retry.
504timeoutThe request took too long. Safe to retry.

Every response carries an x-request-id header. Quote it when you contact support.

Data handling

The API does not store prompt or completion text. For billing, it records the token counts, timings, model and cost of each request, and shows them in the console.

Support

Questions or problems: contact Qorinix. Include the x-request-id of the affected request. Do not send your API key.