Getting Started
- Go to /signup
- Sign in with Google
- Copy your API key (starts with 32 hex characters)
- Start making requests
Authentication
Use Bearer token in the Authorization header. All requests must include a valid API key.
Authorization: Bearer YOUR_API_KEY
Base URL
All API endpoints are served under the following base URL:
https://api.atlasbrain.cloud/v1
Available Models
The following models are available through the Atlas Gateway API.
- Loading models...
Atlas routing models
Two routing models, atlas/alloy and atlas/alloy-pro, are available on the same endpoint as every other model. They are Atlas Brain's own orchestration on top of third-party models — not models we trained.
atlas/alloy
- Atlas routing model
- Loading live request cost...
- All tiers
atlas/alloy-pro
- Atlas routing model
- Loading live request cost...
- Pro & Premium only
Usage. Call them like any chat model: POST /v1/chat/completions with "model": "atlas/alloy". Supported parameters: messages, stream, max_tokens, tools / tool_choice and reasoning_effort (low | medium | high, default medium).
Each call consumes its live catalog cost from your 5h/7d rate windows (bonus requests count too) and one concurrent slot. Responses are standard OpenAI chat completions.
cURL
curl https://api.atlasbrain.cloud/v1/chat/completions \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "model": "atlas/alloy", "messages": [{"role": "user", "content": "Explain CRDTs in two paragraphs."}] }'
Python (openai library)
from openai import OpenAI client = OpenAI( base_url="https://api.atlasbrain.cloud/v1", api_key="YOUR_API_KEY" ) response = client.chat.completions.create( model="atlas/alloy", messages=[{"role": "user", "content": "Explain CRDTs in two paragraphs."}] ) print(response.choices[0].message.content)
Atlas Code — the official CLI
Atlas Code is our first-party terminal coding agent, built for Atlas Gateway. It plans, writes, and verifies code in your repository against Atlas Gateway (beta) — no API keys to paste into configs, no wire setup. The command is atlas; the original alloy command still works.
# 1. Install — one command (SHA-256 verified, signed release): # Windows (PowerShell): irm https://atlasbrain.cloud/install.ps1 | iex # macOS / Linux: curl -fsSL https://atlasbrain.cloud/install | sh # 2. Sign in (opens your browser; key lands in your OS keychain) atlas login # 3. Go atlas # interactive terminal UI atlas run "fix the bug" # headless one-shot mission atlas review # AI review of your git diff (read-only) atlas watch "npm test" # re-check on change, --fix auto-repairs atlas playbook # staged mission templates atlas doctor # connectivity + auth self-check
What you get. Missions with live plans and receipts, playbooks that survive restarts, a rewindable session timeline, project skills and agents in .alloy/, and a thinking-level slider from quick answers to deep reasoning. Signed releases — every archive is verifiable against the published release key.
Manual download → · Free tier works out of the box; Pro & Premium also include the atlas/alloy-pro routing model.
Preview channel (beta)
Prereleases carry the newest features first — less battle-tested, same signed and hash-verified install path. Install the current preview build with:
# Windows (PowerShell): irm https://atlasbrain.cloud/install-beta.ps1 | iex # macOS / Linux: curl -fsSL https://atlasbrain.cloud/install-beta | sh
When a preview proves stable it graduates to the official release above. Running a preview? Tell us what breaks — that feedback is what gets features promoted.
Use with Coding Agents
Atlas Gateway speaks three wire protocols — OpenAI Chat Completions, the Anthropic Messages API, and the OpenAI Responses API — so every major coding agent connects with a copy-paste config. Tool-bearing requests automatically get strict byte-standard wire output.
Claude Code
# macOS / Linux export ANTHROPIC_BASE_URL="https://api.atlasbrain.cloud" export ANTHROPIC_AUTH_TOKEN="YOUR_API_KEY" export ANTHROPIC_MODEL="atlas/alloy" export API_TIMEOUT_MS=300000 claude # Windows (cmd) set ANTHROPIC_BASE_URL=https://api.atlasbrain.cloud set ANTHROPIC_AUTH_TOKEN=YOUR_API_KEY set ANTHROPIC_MODEL=atlas/alloy set API_TIMEOUT_MS=300000 claude
ANTHROPIC_API_KEY works too; API_TIMEOUT_MS=300000 is recommended — long turns on atlas/alloy-pro can take a couple of minutes.
Codex CLI (≥0.142)
Add this to ~/.codex/config.toml, then run codex with ATLAS_API_KEY set in your environment:
model = "atlas/alloy" model_provider = "atlas" [model_providers.atlas] name = "Atlas Gateway" base_url = "https://api.atlasbrain.cloud/v1" wire_api = "responses" env_key = "ATLAS_API_KEY" preferred_auth_method = "apikey"
OpenCode
Create opencode.json in your project directory:
{
"$schema": "https://opencode.ai/config.json",
"provider": {
"atlas": {
"npm": "@ai-sdk/openai-compatible",
"name": "Atlas Gateway",
"options": {
"baseURL": "https://api.atlasbrain.cloud/v1",
"apiKey": "YOUR_API_KEY"
},
"models": { "atlas/alloy": { "name": "Alloy 2" } }
}
},
"model": "atlas/atlas/alloy"
}
Continue.dev / Cursor / any OpenAI-compatible tool
Point the OpenAI-compatible provider at https://api.atlasbrain.cloud/v1 with your Atlas key and any model id from /v1/models. Streaming, tool calls, and JSON mode work as standard.
Endpoints
count_tokens. Send your Atlas key in the x-api-key header. Works natively with Claude Code: set ANTHROPIC_BASE_URL=https://api.atlasbrain.cloud, ANTHROPIC_API_KEY to your Atlas key, and ANTHROPIC_MODEL to any Atlas model id.wire_api="responses"). Same Atlas key and models as chat completions; streams end with response.completed.Rate Limits
Rate limits use sliding time windows per plan tier. Bonus requests (earned via ads) are consumed first and bypass window limits.
Free
- 50 req / 5h
- 200 req / 7d
- 20 RPM
- 2 concurrent
Pro
- 500 req / 5h
- 3,000 req / 7d
- 100 RPM
- 8 concurrent
Premium
- 2,500 req / 5h
- 10,000 req / 7d
- 500 RPM
- 24 concurrent
RPM = Requests Per Minute. When you hit a limit, the API returns 429 — free tier: "Limit reached. Watch an ad to continue now, or wait for reset."; paid tiers: "Rate limit reached (concurrent requests or usage window). Please retry in a few seconds."
Bonus & Top-Up Features
Free users can earn bonus requests that bypass rate windows. Bonus priority mode (configurable by admin) controls whether bonus is used before, after, or randomly against the rate window.
- Earn rewards — Loading current bonus values...
- Promo Codes — Redeem codes via
POST /api/topup/promowith{code} - Multi-Key — Create up to 3/5/10 API keys (Free/Pro/Premium) sharing one rate pool
- Referral — Share your link; both users get bonus when the referral watches 3 ads
- Request Log — View your last 20 requests via
GET /api/requests/log - Dashboard Chat — Built-in streaming chat using your own API key
- System Status — Public health at
/system-statusand/api/public/status
Code Examples
cURL
curl https://api.atlasbrain.cloud/v1/chat/completions \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "model": "claude-opus-4.8", "messages": [{"role": "user", "content": "Hello!"}] }'
Python (openai library)
from openai import OpenAI client = OpenAI( base_url="https://api.atlasbrain.cloud/v1", api_key="YOUR_API_KEY" ) response = client.chat.completions.create( model="claude-opus-4.8", messages=[{"role": "user", "content": "Hello!"}] ) print(response.choices[0].message.content)
Python (requests)
import requests resp = requests.post( "https://api.atlasbrain.cloud/v1/chat/completions", headers={"Authorization": "Bearer YOUR_API_KEY"}, json={"model": "claude-opus-4.8", "messages": [{"role": "user", "content": "Hello!"}]} ) print(resp.json()["choices"][0]["message"]["content"])
JavaScript
const response = await fetch( "https://api.atlasbrain.cloud/v1/chat/completions", { method: "POST", headers: { "Authorization": "Bearer YOUR_API_KEY", "Content-Type": "application/json" }, body: JSON.stringify({ model: "claude-opus-4.8", messages: [{role: "user", content: "Hello!"}] }) } ); const data = await response.json(); console.log(data.choices[0].message.content);
Claude Code CLI
# Configure Claude Code to use Atlas Gateway # (ANTHROPIC_BASE_URL is the origin only - no /v1 suffix) claude config set apiKey YOUR_API_KEY
Pass via environment variables:
ANTHROPIC_API_KEY=YOUR_API_KEY \ ANTHROPIC_BASE_URL=https://api.atlasbrain.cloud \ claude
Codex CLI (OpenAI-compatible)
OPENAI_API_KEY=YOUR_API_KEY \ OPENAI_BASE_URL=https://api.atlasbrain.cloud/v1 \ codex
Cursor IDE
In Cursor settings, set the following under the OpenAI-compatible provider:
- OpenAI API Key: YOUR_API_KEY
- OpenAI Base URL: https://api.atlasbrain.cloud/v1
Or use the custom endpoint option with any OpenAI-compatible provider. Select claude-opus-4.8 as your model.
Continue.dev (VS Code extension)
{
"models": [{
"title": "Atlas Gateway",
"provider": "openai",
"model": "claude-opus-4.8",
"apiKey": "YOUR_API_KEY",
"apiBase": "https://api.atlasbrain.cloud/v1"
}]
}
Aider
export OPENAI_API_KEY=YOUR_API_KEY export OPENAI_API_BASE_URL=https://api.atlasbrain.cloud/v1 aider --model claude-opus-4.8
Checking Usage
Query your current usage and rate window stats with a simple GET request:
curl -H "Authorization: Bearer YOUR_API_KEY" \ https://api.atlasbrain.cloud/v1/usage
Response includes rate window usage, bonus request balance, and token counts.
Response format
{
"tier": "free",
"rate_5h_used": 3,
"rate_5h_limit": 50,
"rate_7d_used": 3,
"rate_7d_limit": 200,
"bonus_requests": 15,
"total_tokens": 1520
}
Models Endpoint
GET /v1/models returns all available models and their current operational status. Useful for programmatically discovering which models are available and healthy.
curl -H "Authorization: Bearer YOUR_API_KEY" \ https://api.atlasbrain.cloud/v1/models
Each model entry includes the model ID, owned_by field, and availability status.