Reference — Rev A

API reference

01 exposes an OpenAI-compatible chat-completions API backed by models operated on private EU infrastructure. Swap the base URL and key in an existing OpenAI client.

§ 01

Base URL

https://api.v01ga.run/v1
§ 02

Authentication

Every request needs an Authorization: Bearer 01-sk-... header. Create keys in the dashboard.

§ 03

POST /v1/chat/completions

Non-streaming example:

curl https://api.v01ga.run/v1/chat/completions \
  -H "Authorization: Bearer 01-sk-..." \
  -H "Content-Type: application/json" \
  -d '{
    "model": "01/bonsai-27b",
    "messages": [
      {"role": "system", "content": "You are helpful."},
      {"role": "user",   "content": "Hello!"}
    ]
  }'

Streaming (SSE):

curl https://api.v01ga.run/v1/chat/completions \
  -H "Authorization: Bearer 01-sk-..." \
  -H "Content-Type: application/json" \
  -N \
  -d '{
    "model": "01/bonsai-27b",
    "messages": [{"role": "user", "content": "Count to 5"}],
    "stream": true,
    "stream_options": { "include_usage": true }
  }'
§ 04

OpenAI SDKs

Python:

from openai import OpenAI

client = OpenAI(
    base_url="https://api.v01ga.run/v1",
    api_key="01-sk-...",
)

resp = client.chat.completions.create(
    model="01/bonsai-27b",
    messages=[{"role": "user", "content": "Hi"}],
)
print(resp.choices[0].message.content)

Node / TypeScript:

import OpenAI from "openai";

const client = new OpenAI({
  baseURL: "https://api.v01ga.run/v1",
  apiKey: process.env.ZERO_ONE_API_KEY,
});

const resp = await client.chat.completions.create({
  model: "01/bonsai-27b",
  messages: [{ role: "user", content: "Hi" }],
});
console.log(resp.choices[0].message.content);
§ 05

GET /v1/models

Returns the list of models you can pass as model.

curl https://api.v01ga.run/v1/models
Bonsai 27B
01 · EU private infrastructure · 32,768 ctx
01/bonsai-27b
§ 06

Rate limits

Requests are rate-limited to protect the private inference node. Defaults per API key: 20 requests / minute, 1,000 requests / day, 100,000 tokens / day per account. Exceeding a limit returns 429 with a Retry-After header.

§ 07

Errors

Errors follow the OpenAI envelope so existing SDKs render them:

{
  "error": {
    "message": "Unknown model 'foo'. Available: 01/bonsai-27b.",
    "type": "invalid_request_error",
    "code": "model_not_found"
  }
}
StatusCodeMeaning
400invalid_requestBad JSON or field.
400model_not_foundModel id not in the registry.
401missing_api_keyNo Bearer header.
401invalid_api_keyKey not found or revoked.
429rate_limit_exceededPer-key or per-account limit hit.
429queue_fullPrivate inference capacity is currently full.
503upstream_unavailableModel cooling from an upstream error.
01 by V01GA — Private EU AI inference