EN ▾
Claim trial key

Uncensored OpenAI-compatible API

Quickstart Guide

Integrate our uncensored AI into your application by pointing your OpenAI-compatible SDK to our endpoint. This guide covers authentication, requests, streaming, and limits for reliable NSFW text generation.

Prerequisites and API Key

Obtain your key via the dashboard using Google or email. No phone number is required. Every new account receives $0.50 trial credit for 7 days.

Base URL and Authentication

Set the base URL to HTTPS://api.llmsnsfw.com/v1. Pass your key in the Authorization header. This works with any standard client without custom code.

curl https://api.llmsnsfw.com/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "uncensored",
    "messages": [{"role": "user", "content": "Generate a 500 word description of a dark fantasy scene"}]
  }'

Sending a Basic Completion Request

Send a POST request to /v1/chat/completions. Use model "uncensored" for direct access. The model answers without soft refusals for lawful adult content. It does not support embeddings or image generation.

from openai import OpenAI

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

Handling Streaming Responses

Use Server-Sent Events for token-by-token output. Set stream to true in the body. The final chunk contains usage statistics. This reduces perceived latency for chat interfaces.

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)

Configuring Parameters for NSFW

Adjust temperature and top_p for creative output. Use stop sequences to control length. JSON mode forces structured output. These parameters work exactly as defined in the OpenAI spec.

import OpenAI from "openai";

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

Error Handling and Token Limits

Monitor for 401 invalid key or 402 no credit errors. Rate limit is 300 requests per minute. Context window is 100,000 tokens total. Output maxes at 16,000 tokens unless specified otherwise.

Common questions

Is this a standard OpenAI compatible API?

Yes. We provide a single uncensored model via a standard OpenAI-compatible endpoint. You can use the official SDKs by changing the base URL and API key. This ensures predictable behavior and lower latency.

What happens if I run out of credit?

Requests fail with a 402 error. Credit is charged by real token usage. Errors and refusals are free. You can top up with USDT or USDC at any time.

Does the model refuse NSFW topics?

The model is tuned to answer without content refusals for lawful adult use. It does not refuse sexual content, fantasy, or roleplay. The only hard limit is no sexual content involving minors.

Retrieve your API key

Register, copy your token, and update your base URL. That is all.

Claim trial key