API REFERENCE & DOCS

AeroX AI Reference & SDK Documentation

Welcome to the official developer API documentation. AeroX AI provides high-performance, low-latency AI inference with native dual wire-compatibility for both the OpenAI Chat Completions API and the Anthropic Messages API.

Authentication & Secret Keys

Every request to the AeroX API requires a cryptographic API key. You can generate keys in the Developer Portal. Pass your secret key in the HTTP request headers using either standard convention:

HTTP Request Header Options
# Option 1 (OpenAI standard):
Authorization: Bearer ax-live-your-secret-key

# Option 2 (Anthropic standard):
x-api-key: ax-live-your-secret-key

Dual Compatible Endpoints

AeroX routes requests through identical endpoints mapped under both /v1 and /api/v1. Simply update the base_url in your existing codebase or agent SDK without refactoring prompts or tools.

Base URL Paths
Base URL 1: /v1
Base URL 2: /api/v1

Quickstart Guide

Get up and running in under 2 minutes using cURL, the official OpenAI Python SDK, or the Anthropic Python library.

Set Up AeroX With Coding Agents

Choose Codex CLI or Claude Code, install the client, connect it to your AeroX API key, then run it inside a real project folder.

Claude Code Setup

Anthropic-compatible client setup through AeroX. Configure Claude Code to use your AeroX API key and endpoints.

01

Install Claude Code

Recommended method: native PowerShell installer. Alternative: WinGet.

powershell
irm https://claude.ai/install.ps1 | iex # or winget install Anthropic.ClaudeCode
Install Git for Windows if you want Claude Code to use Git Bash. Without it, Claude Code can still use PowerShell.
02

Create an AeroX API Key

Open the API Keys page, create a key, and copy it once.

Treat this key like a password. Anyone with it can spend your AeroX balance and plan limits.
03

Create settings.json

Save this file at C:\Users\YOUR_USERNAME\.claude\settings.json.

powershell
New-Item -ItemType Directory "$env:USERPROFILE\.claude" -Force
json (settings.json)
{
  "env": {
    "ANTHROPIC_API_KEY": "YOUR_AEROX_API_KEY",
    "ANTHROPIC_BASE_URL": "https://capi.aerox.lat/",
    "CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC": "1"
  },
  "permissions": {
    "allow": [],
    "deny": []
  }
}

Replace YOUR_AEROX_API_KEY with your real key.

If you used an older AeroX setup, remove the apiKeyHelper entry from your settings. A stale helper can override the API key above and cause a 401 Unauthorized - Invalid token error.
04

Verify and Start

Verify your installation, run diagnostic checks, and launch Claude Code inside your project directory:

bash / powershell
claude --version
claude doctor
cd path-to-your-project
claude

Frequently Asked Questions

Which should I pick?
Use Codex when you want GPT models and the Codex CLI/VS Code workflow. Use Claude Code when your workflow expects Anthropic-compatible tooling or Claude Code project behavior.
Why do both guides mention Git?
Git is not required for every command, but real projects use it for history, undo, branches, collaboration, and deployment. Agents also use Git status and diffs to avoid mixing unrelated work.
Why is the provider named AeroX?
AeroX is the gateway. Your tools should point at AeroX base URLs, never another provider name.
Claude Base URL
https://capi.aerox.lat/

Codex CLI Setup

GPT agent workflow with AeroX Responses API routing. Route Codex CLI to AeroX high-throughput models.

01

Install Codex CLI

Install Node.js LTS first, then install Codex from your terminal:

bash / powershell
node --version
npm install -g @openai/codex
On Windows, keep your project in a normal folder such as C:\Users\YOUR_USERNAME\projects\my-app. Do not use your .codex settings folder as the project.
02

Create an AeroX API Key

Open the API Keys page, create a key, and copy it once.

Treat this key like a password. Anyone with it can use your AeroX balance and plan limits.
03

Create the Codex Settings Folder

Create a clean settings directory for Codex:

powershell
Remove-Item -Recurse -Force "$env:USERPROFILE\.codex" -ErrorAction SilentlyContinue
New-Item -ItemType Directory "$env:USERPROFILE\.codex"
04

Create auth.json

Save this file at C:\Users\YOUR_USERNAME\.codex\auth.json:

json (auth.json)
{
  "OPENAI_API_KEY": "YOUR_AEROX_API_KEY"
}

Replace YOUR_AEROX_API_KEY with the key from step 2.

05

Create config.toml

Save this file at C:\Users\YOUR_USERNAME\.codex\config.toml:

toml (config.toml)
model_provider = "aerox"
model = "gpt-5.6-sol"
model_reasoning_effort = "high"
disable_response_storage = true
preferred_auth_method = "apikey"

[model_providers.aerox]
name = "aerox"
base_url = "https://cgapi.aerox.lat/v1"
wire_api = "responses"

[windows]
sandbox = "elevated"
This routes Codex to AeroX with the Responses wire API and gpt-5.6-sol.
06

Optional: Trust a Project Folder

If Codex asks whether to trust a project, approve it in the UI. Advanced users can add a project entry like this to config.toml:

toml
[projects.'C:\Users\YOUR_USERNAME\your-project']
trust_level = "trusted"

Replace the path with your real project folder.

07

Verify and Start

Check the Codex CLI version and launch it in your project repository:

bash / powershell
codex -V
cd path-to-your-project
codex
The official VS Code extension is also supported. Use the same AeroX API key and provider settings when it asks for configuration.

Frequently Asked Questions

Which should I pick?
Use Codex when you want GPT models and the Codex CLI/VS Code workflow. Use Claude Code when your workflow expects Anthropic-compatible tooling or Claude Code project behavior.
Why do both guides mention Git?
Git is not required for every command, but real projects use it for history, undo, branches, collaboration, and deployment. Agents also use Git status and diffs to avoid mixing unrelated work.
Why is the provider named AeroX?
AeroX is the gateway. Your tools should point at AeroX base URLs, never another provider name.
Codex Base URL
https://cgapi.aerox.lat/v1

OpenAI-Compatible: Chat Completions API

POST /v1/chat/completions accepts standard OpenAI request bodies, including streaming (stream: true), multi-turn message arrays, temperature, and token caps.

curl -X POST "${window.location.origin}/v1/chat/completions" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer ax-live-your-secret-key" \
  -d '{
    "model": "aerox-pro",
    "messages": [
      {"role": "system", "content": "You are an expert AI assistant."},
      {"role": "user", "content": "Hello AeroX!"}
    ],
    "temperature": 0.7,
    "stream": false
  }'

Anthropic-Compatible: Messages API

POST /v1/messages supports external tools, Claude SDK integrations, and multi-turn workflows using the standard Anthropic payload structure.

curl -X POST "${window.location.origin}/v1/messages" \
  -H "Content-Type: application/json" \
  -H "x-api-key: ax-live-your-secret-key" \
  -H "anthropic-version: 2023-06-01" \
  -d '{
    "model": "aerox-pro",
    "max_tokens": 1024,
    "system": "You are a concise engineering assistant.",
    "messages": [
      {"role": "user", "content": "Explain async I/O in 10 words."}
    ]
  }'

Available Models & API Model IDs

Only models entitled to your current subscription plan are accessible. Requesting a model outside your plan returns a 403 Permission Error.

Model Name API Model ID Context Window Credit Cost
AeroX Hyperion 2 aerox-hyperion-3 1,048,576 tokens 1.2 cr / req

Rate Limits & Quotas

AeroX AI applies sliding-window rate limiting per API key and client network IP address to guarantee service availability.

  • Requests Per Minute: 60 RPM default (configurable in Admin Panel).
  • Credit Deductions: Each API request deducts credits in real time from your account balance.
  • 5-Hour Rolling Window: API calls enforce the 5-hour rolling usage limit assigned to your plan tier.

Error Codes & Handling

AeroX returns standard HTTP status codes along with protocol-appropriate error objects:

Status Code / Type Description
401 invalid_api_key API key is missing, invalid, or has been revoked.
403 permission_error Requested model is restricted from your subscription plan, or API system is disabled.
404 model_not_found Model ID does not exist or is disabled.
429 rate_limit_exceeded / insufficient_quota Too many requests or user credit balance is depleted.
✓ Copied to clipboard