API Documentation
Complete reference for integrating with Routeon. OpenAI-compatible endpoints with drop-in replacement support.
Quick Start
1from openai import OpenAI23# Initialize client with Routeon base URL4client = OpenAI(5 base_url="https://api.routex.dev/v1",6 api_key="sk-your-api-key"7)89# Create chat completion10response = client.chat.completions.create(11 model="gpt-4",12 messages=[13 {"role": "system", "content": "You are a helpful assistant."},14 {"role": "user", "content": "Hello!"}15 ],16 temperature=0.7,17 max_tokens=102418)1920print(response.choices[0].message.content)User Guide
A step-by-step walkthrough for using Routeon as a developer or team.
01.Sign up for an account
Create your Routeon account, verify your email, and sign in to the developer console to begin.
Create Account02.Create an API key
Go to API Keys in the console, create a key with a descriptive name, and store it securely in an environment variable.
API Key Security03.Make your first API request
Use any OpenAI-compatible SDK or cURL by pointing the base URL to Routeon and including your API key.
Try the Playground04.Monitor usage and logs
Visit the Usage dashboard to view request volume, token consumption, costs, and latency trends.
Usage & Logs05.Recharge and set budgets
Add prepaid credits and configure budgets at tenant, project, or key level to control spending.
Rate LimitsAuthentication
Routeon uses Bearer token authentication for API access. Include your API key in the Authorization header of every request.
Authorization: Bearer sk-your-api-keyBearer Token
For API access from applications and services
Session
For browser-based access to management APIs
Service Status
Public gateway endpoints and health probes. All endpoints are versioned under /v1 and follow standard HTTP semantics.
Gateway API
Core chat completion, FIM, and message endpoints. OpenAI and Anthropic compatible.
Rate Limits
Rate limits are enforced per API key. Check headers: X-RateLimit-Limit,X-RateLimit-Remaining,X-RateLimit-Reset
Error Handling
1{2 "error": {3 "type": "invalid_request_error",4 "message": "Detailed error description",5 "code": "invalid_api_key"6 }7}Ready to start building?
Sign up for a free account and get started with the API playground.