Quickstart: Integrate the Uncensored Model
Stop wrestling with content filters and start generating uncensored text immediately. This guide gets you connected to the open-weight uncensored LLM via our openai compatible API in under two minutes.
Authentication & Base URL
Your API key is the only credential you need. Generate it instantly on the Get API key page using Google or an email password. No phone number, no subscription, just a key that works with standard OpenAI SDKs.
- Base URL:
https://api.tokennsfw.com/v1 - Auth Header:
Authorization: Bearer YOUR_API_KEY
The model identifier is always uncensored. This is a single open-weight model, not GPT or Claude, hosted on our own servers. It answers adult content requests without typical refusals.
Sending Your First Request
Send a standard chat completion request to generate text. The endpoint accepts your system prompt to define the uncensored behavior and user input for immediate results.
curl https://api.tokennsfw.com/v1/chat/completions \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "uncensored",
"messages": [{"role": "user", "content": "Show me my current token balance."}]
}'The response returns a text completion. If you hit an error like 401, check your key. If you see 402, your prepaid credit is exhausted. Errors during generation are free, so you only pay for successful tokens.
Python SDK Integration
Use the official openai Python package. Point it to our base URL and set the model to uncensored. This ensures compatibility with the tools you already know.
from openai import OpenAI
client = OpenAI(base_url="https://api.tokennsfw.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)Set parameters like temperature or top_p to control creativity. The API supports standard JSON formatting and stops sequences. Keep your code simple; the hard work of content filtering is already done.
Node SDK Usage
Install the openai Node package and configure the base URL. This works seamlessly with JavaScript and TypeScript projects requiring unrestricted text generation.
import OpenAI from "openai";
const client = new OpenAI({ baseURL: "https://api.tokennsfw.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);Handle the response object to extract the generated content. You can adjust presence_penalty or frequency_penalty to refine the output style. The API key is passed via the standard authorization header.
Streaming Responses (SSE)
Enable real-time token delivery by setting stream: true. The API uses Server-Sent Events (SSE) to send partial responses as they are generated.
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)Token usage statistics appear in the final chunk. This is ideal for chat interfaces where users expect immediate feedback. You can parse the stream to display text character-by-character or word-by-word.
Rate Limits & Constraints
Each API key supports 300 requests per minute and 8 concurrent requests. The maximum request body size is 8 MB. You get a 100,000 token context window for input and output combined.
Max output is 16,000 tokens per request. If you do not set max_tokens, it defaults to 2,048. Refusals for minor sexual content are free. Errors do not consume credit, ensuring you only pay for actual usage.
Common questions
What does 'uncensored' mean for the token NSFW model?
The model does not refuse lawful adult, fictional, or controversial topics. It is tuned to answer without content filters, though it still blocks sexual content involving minors. It is not GPT, Claude, or any other vendor's model.
How do I top up my prepaid credit?
Top up using crypto only: USDT (TRC20) or USDC (Base). Minimum is $20, maximum is $500. You get bonus credit: +5% from $50, +10% from $100, and +15% from $200. Credit never expires.
Which payment methods do you accept?
Crypto only: USDT on TRC20 or USDC on Base, any whole amount from $20 to $500. Bonus credit applies from $50.
Generate your key instantly
Register, grab your key, update the endpoint. Done.