Documentation

Build on the OneAI commercial API.

OneAI is the model-routing and structured-intelligence layer. Use /v1/generate for task intelligence, /v1/chat/completions for OpenAI-compatible gateway calls, /v1/messages for Messages-style gateway calls, and /v1/models for catalog discovery.

Product Guide

Positioning, API surfaces, task list, cost controls, and commercial usage.

Trust Center

Security, SLA, DPA, privacy, execution boundary, and enterprise trust controls.

Use Cases

Customer-facing scenarios for strategy, content, support, market intelligence, and custom tasks.

Production Checklist

Security, cost controls, idempotency, usage, and launch verification.

Task Examples

Copyable request and output examples for commercial tasks.

Agent OS Preview

Capabilities, agent plans, handoff preview, and context preview without execution.

Agent OS Versioning

Protocol versions, compatibility rules, executor checklist, and OneClaw/OpenClaw expectations.

Quickstart

Make the first /v1/generate call.

API Basics

Auth, request shape, response metadata.

Generate Reference

Task input, options, usage, trace.

Chat Completions

OpenAI-compatible model gateway calls.

Messages

Anthropic-style Messages API through OneAI model routing.

Models

Catalog, health checks, pricing coverage.

SLA

Enterprise service-level expectations and support boundary.

DPA

Customer data processing, provider routing, and deletion/export path.

Invoices

Stripe portal, manual invoices, billing evidence, and plan changes.

Enterprise Contract

Order form, MSA, DPA, SLA, billing, and support contract pack.

Terms

Service boundary, acceptable use, API key responsibility, and plan limits.

Privacy

Account data, request data, secrets, logs, and customer requests.

Errors

Retryable failures and customer-safe errors.

Rate Limits

API key policy and production limits.

Schemas

Structured output contracts.

Production request
curl https://oneai-saas-api-production.up.railway.app/v1/generate \
  -H "content-type: application/json" \
  -H "x-api-key: $ONEAI_API_KEY" \
  -H "Idempotency-Key: business-strategy-001" \
  -d '{
    "type": "business_strategy",
    "input": {
      "goal": "Create a launch plan for OneAI API",
      "audience": "SaaS builders",
      "constraints": ["Keep it practical"]
    },
    "options": { "llm": { "mode": "cheap", "maxCostUsd": 0.03 } }
  }'