pl ▾
Claim trial key

Quickstart for developers

Stop wrestling with moderation filters and start generating text. This quickstart gets you from zero to a working uncensored LLM API call in minutes using standard OpenAI-compatible tools.

Base URL and authentication

Point your client at https://api.nsfwclaude.com/v1 and pass your key in the Authorization header. You get one active key per account; generating a new one revokes the old. Sign up with Google or email and the key appears immediately. No phone number is required.

  • Base URL: https://api.nsfwclaude.com/v1
  • Auth header: Authorization: Bearer YOUR_API_KEY
curl https://api.nsfwclaude.com/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "uncensored",
    "messages": [{"role": "user", "content": "Generate the markdown for a REST API endpoint"}]
  }'

The chat completions endpoint

Send a POST request to /v1/chat/completions with the model ID uncensored. This model answers without refusing lawful adult topics, but it is not a proxy for other vendors. It is an open-weight model tuned for this specific behavior. Set the context window to 100,000 tokens for long conversations.

from openai import OpenAI

client = OpenAI(base_url="https://api.nsfwclaude.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 and token usage

Enable streaming by setting stream: true in your request. The server sends Server-Sent Events (SSE) chunks. Token usage data appears only in the final chunk. This is crucial for tracking costs accurately without waiting for the full response to finish.

import OpenAI from "openai";

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

Function calling and tools

Define your tools in the tools array and set tool_choice to auto or required. The model supports standard function calling formats. Use this to integrate the API into your own applications or bots. JSON mode is also available via response_format for structured outputs.

JSON mode for structured output

Force JSON output by setting response_format to {"type": "json_object"}. This ensures the model returns valid JSON, which is essential for programmatic use. Combine this with function calling for robust API integrations. The model handles complex structures reliably.

Rate limits and concurrency

You are limited to 300 requests per minute per key. You can have up to 8 concurrent requests. The request body must not exceed 8 MB. If you hit these limits, you will receive a 429 error. Handle retries with exponential backoff. Errors and refusals do not consume your prepaid credit.

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

What is the context window for this API?

The context window is 100,000 tokens for both prompt and completion combined. You can request up to 16,000 tokens in a single response. If you do not set <code>max_tokens</code>, the default output is 2,048 tokens.

Why am I getting a 401 or 402 error?

A 401 error means your API key is invalid or revoked. A 402 error indicates you have insufficient prepaid credit. Top up with USDT or USDC to continue. Errors do not cost you credits.

Is this the same as the official Claude API?

No. This is an independent service running an open-weight uncensored model. We are not Anthropic. Use the same client code, but point it to our base URL and use the model ID <code>uncensored</code>.

Generate your API key

Register, copy the key, update the base URL. That is the entire setup.

Claim trial key