Skip to main content

Overview

The Stratus X1 API provides world model predictions for autonomous agents. It’s designed to be OpenAI-compatible, allowing you to use existing SDKs and tools with minimal changes. Base URL: https://api.stratus.run/v1

Available Endpoints

Stratus provides 6 core endpoints:

Chat Completions

POST /v1/chat/completionsOpenAI-format predictions with world model planning

Messages

POST /v1/messagesAnthropic-format predictions (Claude SDK compatible)

Embeddings

POST /v1/embeddingsGet semantic embeddings for state descriptions

Rollout

POST /v1/rolloutMulti-step action prediction and plan validation

LLM Key Management

POST/GET/DELETE /v1/account/llm-keysSecurely store user LLM provider keys (BYOK)

Health Check

GET /healthAPI status, model availability, and vault connection

Authentication

All endpoints (except /health) require authentication using your Stratus API key in the Authorization header:

API Key Format

All Stratus API keys use the format stratus_sk_live_*. Generate yours from the dashboard. See Authentication for detailed setup instructions.

LLM Keys (Optional)

Stratus includes Formation’s shared OpenRouter pool as a universal fallback — no provider API account needed. LLM provider keys are optional and used as an upgrade path to remove the 25% pool markup. Key resolution order per request:
  1. Inline headers (X-OpenAI-Key, X-Anthropic-Key, X-Google-Key, X-OpenRouter-Key) — highest priority
  2. Vault-stored keys (set via POST /v1/account/llm-keys) — used automatically when present
  3. Formation’s pool — transparent fallback; 25% markup applied to credit cost
When Formation’s pool is used, the response includes stratus.key_source: "formation" and stratus.formation_markup_applied: 0.25. BYOK requests return key_source: "user" and formation_markup_applied: null. See LLM Key Management for vault storage setup and Authentication for the full breakdown.

Quick Start

TypeScript / Node.js

Python

cURL

SDK Compatibility

Stratus is compatible with official SDKs from OpenAI and Anthropic: No custom SDK needed - just point existing tools to https://api.stratus.run/v1.

Response Format

All Stratus responses include standard fields plus optional Stratus-specific metadata:
The stratus field provides insight into world model planning and billing:
  • stratus_model - World model size used
  • execution_llm - LLM used for text generation
  • key_source - "user" (BYOK) or "formation" (Formation’s pool)
  • formation_markup_applied - 0.25 when pool was used; null for BYOK
  • action_sequence - Predicted action sequence
  • confidence - Planning confidence (0-1)
  • planning_time_ms - Time spent in world model
  • execution_time_ms - Time spent in LLM

Error Handling

Stratus uses standard HTTP status codes and returns errors in OpenAI-compatible format:
Common status codes:
  • 400 - Bad request (invalid parameters)
  • 401 - Authentication failed (invalid API key)
  • 403 - Permission denied
  • 404 - Resource not found
  • 429 - Rate limit exceeded
  • 500 - Server error
  • 503 - Service unavailable
See Errors for complete reference.

Rate Limits

Rate limiting is not currently enforced. If you receive a 429 response in the future, implement exponential backoff and retry.

Streaming

Both Chat Completions and Messages endpoints support streaming via Server-Sent Events (SSE):

Tools & Function Calling

Stratus supports OpenAI-compatible function calling with up to 100 tools per request:
See Chat Completions - Tools & Function Calling for complete documentation.

Models

Stratus supports 2,050+ model combinations across:
  • 5 world model sizes: small, base, large, xl, huge
  • Native LLM variants: GPT-4o, GPT-4o Mini, Claude Sonnet/Opus/Haiku 4.5, etc.
  • OpenRouter models: Every model in OpenRouter’s catalog via {or-provider}/{or-model} notation
Native format: stratus-x1ac-{size}-{llm} OpenRouter format: stratus-x1ac-{size}-{or-provider}/{or-model} Native examples:
  • stratus-x1ac-base-gpt-4o - Recommended for production
  • stratus-x1ac-small-gpt-4o-mini - Fastest/cheapest for development
  • stratus-x1ac-base-claude-sonnet-4-20250514 - Claude Sonnet 4
OpenRouter examples:
  • stratus-x1ac-base-deepseek/deepseek-r1 - DeepSeek R1 reasoning
  • stratus-x1ac-base-meta-llama/llama-3.3-70b-instruct - Llama 3.3 70B
  • stratus-x1ac-base-google/gemini-2.5-pro - Gemini 2.5 Pro
  • stratus-x1ac-base-x-ai/grok-4 - xAI Grok 4
  • stratus-x1ac-base-mistralai/mistral-large-2411 - Mistral Large
  • stratus-x1ac-base-qwen/qwen-2.5-72b-instruct - Qwen 2.5 72B
List all available models programmatically:
See Models for the complete list and all provider categories.

Monitoring & Observability

Health Check

Monitor API status and model availability:
Returns:
  • API health status
  • Loaded world models
  • LLM provider availability
  • Vault connection status
See Health Check for details.

Request Logging

Best practice: Log request metadata for debugging:

Getting Help

Quickstart Guide

Build your first integration in 5 minutes

Authentication

Setup and manage API keys

Use Cases

Real-world examples and patterns

Support

Contact support for help

What’s Next?