API Documentation

Get started with the uncensored AI API in minutes. Use your dedicated API key to send text and receive unconstrained responses immediately.

Base URL and Authentication

Authentication uses a single API key passed in the Authorization header. Every request requires this header to identify your account and track token usage. You receive one active key per account, and generating a new one immediately replaces the previous key. This ensures you always have a clean credential for your integration.

curl https://api.trulyuncensoredai.com/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "uncensored",
    "messages": [{"role": "user", "content": "List the top 10 python libraries for data analysis"}]
  }'

First Request

The first request confirms your integration works with the uncensored LLM API. Send a simple prompt to verify the model responds without standard refusals. You can use the official OpenAI SDKs or any compatible client by pointing to our base URL. This step validates that your key is active and credit is available.

from openai import OpenAI

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

Node SDK Integration

Integrate directly into your JavaScript or TypeScript projects using the Node SDK. Configure the base URL and API key once, then call the chat completions endpoint. This approach keeps your code clean and handles authentication automatically. It is ideal for server-side rendering or backend services.

import OpenAI from "openai";

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

Streaming Responses

Enable streaming to receive tokens as they are generated. This reduces perceived latency for long-form roleplay or creative writing tasks. The final chunk contains the total token usage for accurate billing. Streaming works seamlessly with standard SSE parsers in most modern SDKs.

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)

Limits and Errors

Rate limits enforce 300 requests per minute and 8 concurrent requests per key. A 401 error means your key is invalid or revoked. A 402 error indicates insufficient prepaid credit. A 429 error signals you have exceeded the rate limit. Always handle these errors gracefully to avoid broken user experiences.

Context Window

The model supports a 100,000 token context window for both input and output combined. This allows for extensive history in roleplay scenarios or large document analysis. Output is capped at 16,000 tokens per request, or 2,048 if you do not specify max_tokens. Monitor your token usage to stay within these bounds.

Common questions

How do I get started with the uncensored AI API?

Sign up using Google or email to receive an API key instantly. Add your prepaid credit via crypto, then send your first request to the chat completions endpoint. The model responds immediately without soft refusals for lawful adult content.

What happens if I exceed the rate limit?

You will receive a 429 status code indicating you have hit the 300 requests per minute or 8 concurrent request limit. Wait a short period before retrying, or optimize your client to reduce concurrent connections. Limits are enforced per API key.

Is the uncensored LLM online always available?

The API is hosted on our dedicated servers with no vendor routing. While we aim for high uptime, there are no SLA guarantees. Check the status page for any planned maintenance or incidents.

Get your API key

Register, copy your key, update your base URL. That’s it.