fa ▾
Open account

Uncensored AI API Documentation

Get started with our uncensored AI API in minutes using standard OpenAI-compatible endpoints. Authenticate with your key and send text to receive raw, uncensored model outputs.

Base URL and Authentication

The API base URL is HTTPS://api.openrouteruncensoredmodel.com/v1. You authenticate by passing your API key in the Authorization header. Every request must include this header to verify your account and track usage. Generate your key via the dashboard using Google or email sign-up.

curl https://api.openrouteruncensoredmodel.com/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "uncensored",
    "messages": [{"role": "user", "content": "list core concepts of rust ownership"}]
  }'

Chat Completions Endpoint

Send messages to the /v1/chat/completions endpoint for text generation. The model ID is uncensored. This endpoint handles standard chat formats with system, user, and assistant roles. It returns structured JSON responses containing the generated text.

from openai import OpenAI

client = OpenAI(base_url="https://api.openrouteruncensoredmodel.com/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)

Streaming Responses via SSE

Enable streaming by setting stream: true. The API returns Server-Sent Events (SSE) for real-time token delivery. Token usage metrics appear in the final chunk of the stream. This approach reduces perceived latency for long responses.

import OpenAI from "openai";

const client = new OpenAI({ baseURL: "https://api.openrouteruncensoredmodel.com/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);

Parameters: Temperature, Top P, and JSON Mode

Control randomness with temperature and top_p values. Use response_format: {"type": "json_object"} for structured outputs. The model supports function calling and tool definitions. Set max_tokens to limit output length, defaulting to 2,048 if unspecified.

Rate Limits and Quotas

Each key allows 300 requests per minute and 8 concurrent requests. The maximum request body size is 8 MB. Exceeding these limits returns a 429 status code. Ensure your client handles retries appropriately during high-load periods.

Model Information and Context Window

The model supports a 100,000-token context window combining prompt and completion. Errors and refusals do not consume credit. Check GET /v1/models for current model details. Use the uncensored model ID for all requests.

Streaming

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)

Common questions

How do I authenticate with the openrouter uncensored model API?

Include your API key in the <code>Authorization: Bearer <key></code> header. Keys are generated via the dashboard using Google or email. Each account has one active key at a time.

What happens if I hit the rate limit?

Requests return a 429 status code. You can make 300 requests per minute per key. Wait before retrying or use a secondary key if available.

Is the uncensored LLM API compatible with OpenAI SDKs?

Yes. It uses the <code>/v1/chat/completions</code> endpoint. Change the base URL in your OpenAI client to point to our API. Send model ID <code>uncensored</code> for responses.

Get your API key instantly

Sign up, copy the token, update your base URL. That is the entire workflow.

Open account