pl ▾
Get your key

API Quickstart

Get your API key and start sending requests to our uncensored LLM endpoint in minutes. This guide covers the OpenAI-compatible interface, streaming, and exact limits you need for integration.

Authentication and base URL

Our API uses standard API key authentication over HTTPS. Simply sign in with Google or your email address to retrieve your key immediately.

Sending your first chat completion

Send a text request to the /v1/chat/completions endpoint using any HTTP client. The model ID is always uncensored.

The system accepts standard parameters like temperature and top_p. Input tokens are charged at $0.15 per million, and output tokens at $0.50 per million. Errors do not consume credit.

curl https://api.chatgptnsfw.com/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "uncensored",
    "messages": [{"role": "user", "content": "Send me the latest server status report"}]
  }'

Python SDK integration

Use the official openai Python library with a custom base URL. This ensures compatibility with your existing codebase while leveraging our uncensored model.

Set the environment variable or pass the key directly. The response structure mirrors OpenAI's standard format, including content and finish reasons.

from openai import OpenAI

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

Initialize the Node.js client with your base URL and API key. This approach works seamlessly with fetch or the official SDK.

Handle the response object to extract the generated text. You can adjust the model behavior using standard parameters like seed or stop sequences.

import OpenAI from "openai";

const client = new OpenAI({ baseURL: "https://api.chatgptnsfw.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 via SSE

Enable streaming by setting stream: true. The API returns Server-Sent Events (SSE) for real-time token delivery.

The final chunk includes the complete usage statistics. This is ideal for applications requiring low latency or progressive text rendering.

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)

Rate limits and constraints

Each key supports 300 requests per minute and 8 concurrent requests. The maximum request body size is 8 MB.

You will receive a 401 error for an invalid key, 402 if prepaid credit is exhausted, and 429 when exceeding rate limits. The context window allows 100,000 tokens total, with a max output of 16,000 tokens.

Common questions

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.

What is the context window size?

The model supports a 100,000 token context window for both prompt and completion. The maximum output per request is 16,000 tokens, or 2,048 tokens if <code>max_tokens</code> is not specified.

Is the uncensored model the same as GPT-4?

No. We run a single, open-weight uncensored LLM tuned for adult content. It is not GPT, Claude, or any other vendor's model. It is a dedicated instance optimized for fewer refusals on lawful adult topics.

Get your API key in minutes

Register, retrieve your key, and update the base URL. Simple integration.

Get your key