AI Uncensored/Journal
OpenAI-compatible API for uncensored text generation
OpenAI Compatible API Uncensored: Switch in 3 Steps
If you want an OpenAI compatible API uncensored enough to skip content refusals on lawful adult work, the migration is three values: base URL, API key and model id. The rest of your OpenAI SDK code keeps its shape.
Last updated
Summary
Change base_url to https://api.aiuncensoredthe.com/v1, use your own key, set model to uncensored.
Chat completions, the Responses API, streaming, tool calling and JSON mode are supported.
Text only: no images, audio, embeddings or fine-tuning, and the context window is 100,000 tokens.
Plan for 429 responses: a full key allows 8 concurrent requests and 300 requests per minute.

Table of contents
- The short answer: three values to change
- Step by step in Python, Node and curl
- Which endpoints and parameters work
- Tool calling and JSON mode keep the same shape
- What will behave differently
- Frameworks and front ends that accept a custom endpoint
- Handling 429 responses in migrated code
- A migration checklist you can follow today
- More guides
The short answer: three values to change
Any app that talks to OpenAI through an official SDK or a plain HTTP call can point at this API. You swap the base URL, the key and the model id. Nothing else in the request shape changes, and the response comes back in the same format your parsing code already expects.
from openai import OpenAI
client = OpenAI(
base_url="https://api.aiuncensoredthe.com/v1",
api_key="YOUR_KEY",
)
reply = client.chat.completions.create(
model="uncensored",
messages=[{"role": "user", "content": "Write a short noir scene set in a rainy port city."}],
)
print(reply.choices[0].message.content)
That is the whole migration for a simple app. Get a key on the API key page; new accounts can claim $0.50 of trial credit with one click, valid for 7 days, to test this exact snippet.
Step by step in Python, Node and curl
Most codebases read the endpoint and key from environment variables, so the cleanest change is in configuration rather than in code. The OpenAI SDKs also read OPENAI_BASE_URL and OPENAI_API_KEY if you do not pass them in the constructor, which means some apps switch with no code edit at all.
Node
import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://api.aiuncensoredthe.com/v1",
apiKey: process.env.UNCENSORED_KEY,
});
const res = await client.chat.completions.create({
model: "uncensored",
messages: [{ role: "user", content: "Give me three villain monologue openers." }],
});
console.log(res.choices[0].message.content);
curl
curl https://api.aiuncensoredthe.com/v1/chat/completions \
-H "Authorization: Bearer $UNCENSORED_KEY" \
-H "Content-Type: application/json" \
-d '{"model": "uncensored", "messages": [{"role": "user", "content": "Hello"}]}'
Auth is a standard Authorization: Bearer header, so proxies, gateways and HTTP libraries that already add that header need no special handling. The API docs list every endpoint and header in one place.
Which endpoints and parameters work
The table below covers what you can rely on. Anything not listed here, test with a small request before you build on it.
| Feature | Status |
|---|---|
POST /v1/chat/completions | Supported |
POST /v1/responses | Supported |
GET /v1/models | Supported, lists the model id uncensored |
Streaming (stream: true) | SSE, usage at the end |
| Tool calling | tools, tool_choice, streamed tool_calls, results as role: "tool" |
| JSON mode | response_format: {"type": "json_object"} |
| Sampling | temperature, top_p, stop, seed and the penalties are passed through |
| Images, audio, video, embeddings, fine-tuning | Not offered |
If your app uses an embeddings endpoint for search or retrieval, keep that part on whatever service you use today and send only the generation step here.
Tool calling and JSON mode keep the same shape
Two features move apps beyond plain chat, and both use the OpenAI request format you already know. Tool calling takes the usual tools list and tool_choice. When the model wants a function run, the reply carries tool_calls; you run the function and send the result back as a message with role: "tool". Streaming works with tools too, with the call arriving in fragments.
from openai import OpenAI
client = OpenAI(base_url="https://api.aiuncensoredthe.com/v1", api_key="YOUR_KEY")
tools = [{
"type": "function",
"function": {
"name": "get_weather",
"description": "Get the current weather for a city",
"parameters": {
"type": "object",
"properties": {"city": {"type": "string"}},
"required": ["city"],
},
},
}]
r = client.chat.completions.create(
model="uncensored",
messages=[{"role": "user", "content": "Is it raining in Lisbon?"}],
tools=tools,
tool_choice="auto",
)
print(r.choices[0].message.tool_calls)
JSON mode is a single parameter, response_format={"type": "json_object"}. As with other OpenAI-style APIs, you get the best results when the prompt also says plainly that the answer must be a JSON object and names the keys you expect. Always parse inside a try block anyway, since a model can still run out of tokens halfway through an object.
What will behave differently
An OpenAI-shaped interface does not mean OpenAI behavior. Four differences matter in practice.
The model is not a GPT model
The id uncensored maps to one open-weight model run by an independent provider. It is not the official API of any model vendor and it is not a router across vendors. Prompts tuned for another model may need small edits: shorter system prompts, plainer instructions, a couple of examples in place of long rule lists.
Refusals are gone, so moderation is yours
The model is tuned to answer without content refusals for lawful adult use. If your product has an audience that needs filtering, add your own checks before and after the call. One limit is fixed: no sexual content involving minors.
The context window is 100,000 tokens
That budget covers prompt plus completion together. max_tokens is optional, and a completion can use whatever the prompt leaves free. Long chat histories fit, but you pay for every input token on every call, so trimming still helps. The pricing page shows the rates: $0.15 per 1M input tokens and $0.50 per 1M output tokens.
Rate limits are explicit
A full key allows 8 concurrent requests and 300 requests per minute. A trial key allows 2 concurrent requests and 60 per minute. Request bodies are capped at 8 MB.
Frameworks and front ends that accept a custom endpoint
You rarely need to edit library code. Most LLM libraries expose a base URL setting on their OpenAI chat class, and many chat front ends have a field for an OpenAI-compatible endpoint. SillyTavern, for example, lets you add an OpenAI-compatible endpoint. In every case you fill in the same three values: the base URL https://api.aiuncensoredthe.com/v1, your key, and the model id uncensored.
If a tool insists on choosing from a fixed model list, check whether it has a "custom model" field. If it calls GET /v1/models to fill the list, it will find the id there. Tools that hard-code a vendor's model names and refuse custom ids are the one case where you may need a small proxy or a patch.
A quick regression script
Before you ship the switch, run your saved prompts against the new endpoint and eyeball the diff. Fifteen to twenty real prompts catch most prompt-tuning problems.
import json
from openai import OpenAI
client = OpenAI(base_url="https://api.aiuncensoredthe.com/v1", api_key="YOUR_KEY")
prompts = json.load(open("saved_prompts.json")) # a list of strings
for p in prompts:
r = client.chat.completions.create(
model="uncensored",
messages=[{"role": "user", "content": p}],
temperature=0.3,
seed=1,
)
print("PROMPT:", p[:60])
print("REPLY: ", r.choices[0].message.content[:300].replace("\n", " "))
print()
Mark each reply as acceptable, needs a prompt edit, or unusable. If the failures cluster around one prompt type, such as strict output formats, tighten that prompt instead of switching back.
Handling 429 responses in migrated code
Apps written against a high-limit vendor often fire dozens of parallel calls. Here, going over a limit returns HTTP 429 with the error code rate_limited (too many requests per minute) or concurrency (too many at once). Temporary overload also returns 429, with a Retry-After: 5 header. A streamed request holds its concurrency slot until the stream ends, so a stalled client can starve your own queue.
The OpenAI SDKs retry 429 by default a couple of times. For batch jobs add a small semaphore sized to your key and a longer backoff:
import time
from openai import OpenAI, RateLimitError
client = OpenAI(base_url="https://api.aiuncensoredthe.com/v1", api_key="YOUR_KEY", max_retries=0)
def ask(messages, tries=4):
for attempt in range(tries):
try:
r = client.chat.completions.create(model="uncensored", messages=messages)
return r.choices[0].message.content
except RateLimitError:
time.sleep(5 * (attempt + 1))
raise RuntimeError("still rate limited after retries")
Failed or refused requests are not charged, so retries do not burn credit on errors.
A migration checklist you can follow today
- Create a key and claim the trial credit from the key page.
- Put the base URL and key in environment variables, not in source.
- Set
modeltouncensoredeverywhere, including fallback branches and test fixtures. - Remove or stub any call to embeddings, image or audio endpoints.
- Run your existing prompts and compare output. Rewrite only the ones that regress.
- Cap concurrency at 8 and add retry on 429.
- Read the balance from the
X-Balance-USDresponse header and alert before it hits zero.
For the balance, you can also call GET /v1/balance or the OpenAI-style GET /v1/dashboard/billing/credit_grants:
curl https://api.aiuncensoredthe.com/v1/balance \
-H "Authorization: Bearer $UNCENSORED_KEY"
Billing is prepaid and pay as you go with no subscription. Credit never expires, and top-ups run from $20 to $500 in any whole amount, paid in crypto (USDT on TRC20 or USDC on Base).
Where to go next
Once the basic call works, add streaming for chat UIs and tool calling for agents, both with the same client object. For a broader tour of what an unfiltered model changes in a product, read the developer guide to the uncensored AI. Prompts are not used for training, which matters if you test with real user text.
More guides
Common Questions About NSFW AI
Is the model truly uncensored? Yes, it does not refuse lawful adult, fictional, or controversial topics. Does it involve sexual content with minors? Requests involving minors are always refused. This is a hard limit. Can I use the OpenAI SDK? Yes, it is fully compatible. You just update the base URL and model id. Is there a free tier? No, but new accounts get $0.50 in trial credit for seven days. How do I pay? Crypto only: USDT (TRC20) or USDC (Base). Amounts range from $20 to $500. Bonus credit is included. Does the API support streaming? Yes, via Server-Sent Events. You can receive tokens in real-time. Is JSON mode supported? Yes, use response_format json_object. Are there rate limits? 300 requests per minute. Eight concurrent requests per key.
Common questions
Do I need a special SDK?
No. The official OpenAI SDKs for Python and Node work after you set the base URL and key. Any HTTP client that can send a Bearer header also works.
Is this the real OpenAI API?
No. It is a separate service with an OpenAI-compatible interface, serving one open-weight model under the id uncensored. It is not affiliated with OpenAI or any model vendor.
Can I keep my embeddings or image calls?
Not here. This API is text only, so keep those calls on the service you use now and move only chat or responses requests.
How do I test before paying?
Sign up with Google or email, then claim $0.50 of trial credit on the API key page. It is valid for 7 days and needs no payment.
Unlock your API key
Register, retrieve your key, and update your endpoint. Minimal configuration required.