API Documentation: Chat Completions
Drop-in uncensored API: change base_url and key, keep the code. You pay only for real tokens with prepaid credit that never expires and no monthly fees.
Base URL and Authentication
The base URL is https://api.routeria.cc/v1. Pass your API key in the Authorization header. Errors and refusals are free, so you only pay for generated tokens.
- GET
/v1/modelslists available models. - POST
/v1/chat/completionshandles text generation.
Authentication is strict. A 401 error means your key is invalid or missing. A 402 error indicates insufficient prepaid credit. You can top up with USDT (TRC20) or USDC (Base).
First Request with cURL
Send a POST request to the chat completions endpoint. The model ID is uncensored. It is an open-weight model tuned to answer without content refusals for lawful adult use.
You must set the Content-Type header to application/json. The request body includes the model ID and your message array.
Errors do not consume your credit. You can verify your key by calling the models endpoint first.
curl https://api.routeria.cc/v1/chat/completions \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "uncensored",
"messages": [{"role": "user", "content": "explain how the router handles packet loss"}]
}'
Python SDK Integration
Use the official OpenAI Python SDK. Set the base URL to https://api.routeria.cc/v1 and provide your API key. The model ID remains uncensored.
This approach keeps your existing code intact. You only change the configuration object. The SDK handles JSON serialization and retry logic automatically.
Streaming is supported via the stream parameter. You receive chunks of text as they are generated.
from openai import OpenAI
client = OpenAI(base_url="https://api.routeria.cc/v1", api_key="YOUR_KEY")
resp = client.chat.completions.create(
model="uncensored",
messages=[{"role": "user", "content": "Summarise this thread without softening it."}],
)
print(resp.choices[0].message.content)
Node SDK Usage
Initialize the client with the correct base URL and API key. Pass the model ID uncensored in your completion calls.
The Node SDK mirrors the Python implementation. You can stream responses or wait for the full completion. Token usage is reported in the final chunk.
Ensure your environment variables store the key securely. The API key is shown immediately upon signup via Google or email.
import OpenAI from "openai";
const client = new OpenAI({ baseURL: "https://api.routeria.cc/v1", apiKey: process.env.API_KEY });
const resp = await client.chat.completions.create({
model: "uncensored",
messages: [{ role: "user", content: "Draft a villain monologue for my game." }],
});
console.log(resp.choices[0].message.content);
Streaming and Token Usage
Enable streaming by setting stream: true in your request. You receive Server-Sent Events (SSE) for each token.
The last chunk contains the complete token usage statistics. Input tokens are charged at $0.15 per 1M tokens. Output tokens cost $0.50 per 1M tokens.
Streaming reduces perceived latency. You can display text as it arrives. The context window supports 100,000 tokens total.
stream = client.chat.completions.create(
model="uncensored",
messages=[{"role": "user", "content": "Tell the story in second person."}],
stream=True,
)
for chunk in stream:
if chunk.choices and chunk.choices[0].delta.content:
print(chunk.choices[0].delta.content, end="", flush=True)
Function Calling and JSON Mode
Enable function calling with the tools parameter. The model supports tool_choice for strict control. Use response_format: {"type": "json_object"} for structured output.
This ensures consistent parsing in your application. The model is optimized for clear, structured responses.
You can combine tools with streaming. The model will invoke functions as needed. All parameters like temperature and top_p are supported.
Parameters: Temperature, Top-P, Stop
Adjust temperature for creativity. Lower values make outputs more deterministic. top_p controls nucleus sampling. Set stop sequences to halt generation.
Other supported parameters include seed, presence_penalty, and frequency_penalty. These allow fine-tuning of the output style.
The default max output is 2,048 tokens. You can increase it up to 16,000 tokens per request. The total context window is 100,000 tokens.
Limits and Quotas
Each API key is limited to 300 requests per minute. You can have 8 concurrent requests per key. The request body size is capped at 8 MB.
A 429 error indicates you have exceeded the rate limit. Wait before retrying. Each account has one active key; a new key replaces the old one.
The model ID is always uncensored. It is not GPT, Claude, or any other vendor's model. It is an open-weight model run on our servers.
Frequently asked questions
Is this the same as OpenAI?
No. We serve an open-weight uncensored model. It is compatible with the OpenAI API format, but it is not GPT. You change the base URL and key to use it.
How do I pay for the API?
We accept crypto only. You can top up with USDT (TRC20) or USDC (Base). The minimum amount is $20. Credit never expires and has no monthly fees.
What is the context window size?
The context window is 100,000 tokens for prompt and completion combined. The maximum output per request is 16,000 tokens. Errors are free and do not count against your limit.
Get your API key now
Sign up, copy the key, update the base URL. Simple setup.