Quickstart for Qwen Abliterated users
Get your first uncensored response in under five minutes by swapping your base URL and API key. This guide covers the essential OpenAI-compatible endpoints for immediate integration.
Authentication and Base URL
Our API follows the standard OpenAI protocol structure. To begin, you must authenticate using a Bearer token. You can generate this key immediately after signing up via Google or email on the Get API key page. The key is displayed once, so copy it securely. All requests must target the specific base URL for our uncensored model.
Set the Authorization header to Bearer YOUR_API_KEY. Ensure your client is configured to use our base URL rather than the default OpenAI endpoint. This ensures your requests route to the correct uncensored inference engine. If you are using a standard SDK, you typically only need to update the base_url configuration and inject your key.
First Request
Verify your integration with a simple chat completion request. This confirms that authentication and routing are working correctly. The endpoint accepts standard chat messages. You can test it with a single turn conversation. If successful, you will receive a token usage summary and the model's response.
curl https://api.qwenabliterated.com/v1/chat/completions \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "uncensored",
"messages": [{"role": "user", "content": "Write a blunt product review of a cheap VPN."}]
}'If you receive a 401 error, check your API key. A 402 error indicates insufficient prepaid credit. Our system charges only for actual tokens consumed; errors and refusals are free.
Python SDK Integration
Use the official openai Python package for rapid development. Initialize the client with your key and our base URL. Set the model ID to uncensored. This ensures the request hits our uncensored model, not a generic aggregator. You can pass system instructions or user messages as standard lists.
from openai import OpenAI
client = OpenAI(base_url="https://api.qwenabliterated.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)This approach works with any OpenAI-compatible Python client. Remember that our model is open-weight and tuned for fewer content refusals. It is not GPT, Claude, or Llama. Adjust your prompt engineering to leverage its direct answering style.
Node.js SDK Setup
For JavaScript environments, the @anthropic-ai/sdk or official openai Node package works seamlessly. Configure the base URL to point to our API. The model ID remains uncensored. This allows you to drop our service into existing Node applications with minimal code changes.
import OpenAI from "openai";
const client = new OpenAI({ baseURL: "https://api.qwenabliterated.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);Ensure your package version supports the required OpenAI API structures. The Node SDK handles JSON serialization automatically. You can pass tools or JSON mode flags directly as standard parameters. This maintains compatibility with your existing client code while switching the inference backend.
Streaming Responses
Enable streaming by setting stream: true in your request. The API returns Server-Sent Events (SSE). Each chunk contains partial text. The final chunk includes the complete token usage data for the request. This is ideal for real-time user 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)Parse the SSE stream to update your UI incrementally. The last event provides the cost and token counts. Streaming does not affect pricing; you are charged for the total tokens processed. Ensure your client handles incomplete JSON chunks if using JSON mode.
Limits and Errors
Our API enforces strict limits to ensure stability. You are allowed 300 requests per minute per key. Concurrent requests are capped at 8 per key. The maximum request body size is 8 MB. The context window is 100,000 tokens for prompt and completion combined. There is no separate output cap, and if max_tokens is unset, the response can run to the end of the window.
Common errors include 401 (invalid key), 402 (insufficient credit), and 429 (rate limit). Credit never expires. If you double-charge, use the Support page to fix it. Prompts are not used for training. One active key per account; generating a new key replaces the old one.
API facts in one table
The numbers below are the real limits of this API, not marketing. Compare them with what your app needs.
| Item | Value |
|---|---|
| API format | OpenAI Chat Completions schema; official openai SDKs work unchanged |
| Model | uncensored |
| Methods | POST /v1/chat/completions · GET /v1/models |
| Base URL | https://api.qwenabliterated.com/v1 |
| Authentication | Authorization: Bearer YOUR_KEY |
| Tools / tool calls | Supported: tools + tool_choice, tool_calls in the reply (streamed too), tool results as role: tool messages |
| Streaming | Supported (stream: true), usage included at the end |
| Max context | 100,000 tokens, input and output combined |
| Other parameters | temperature, top_p, stop, seed and the two penalties are passed through |
| JSON mode | JSON object mode via response_format json_object |
| Completion length | up to the rest of the 100,000-token window; max_tokens optional (no separate cap) |
| Headers | X-Request-Id, X-Balance-USD, X-RateLimit-Limit-Requests, X-RateLimit-Limit-Concurrency |
| Requests per minute | 300 requests per minute per key |
| Concurrency | up to 8 in parallel per key |
| Max body | up to 8 MB per request |
| Billing | pay as you go from prepaid credit; nothing is charged for failed or refused requests |
| Trial credit | $0.50 of credit valid 7 days, no card needed · Trial key: 2 parallel requests, 60 req/min; full limits (8 and 300) after first top-up |
| Token prices | input $0.15 / 1M tokens, output $0.50 / 1M tokens |
| Subscription | no monthly fee; paid credit does not expire |
| Payment | crypto: USDT on TRON or USDC on Base, $20–$500, any whole sum |
| Bonus credit | +5% from $50, +10% from $100, +15% from $200 |
| Content policy | uncensored for adults; the only hard rule: no sexual content involving minors |
| Account | Google or e-mail and password |
| Key management | one active key per account; a new key replaces the old one |
Errors and what to do
The type field is stable, the message is for humans. Errors cost nothing.
| Status | Type | Reason |
|---|---|---|
400 | bad_request | invalid JSON, empty messages, bad parameter, or a prompt longer than the window — fix and resend |
401 | missing_key · invalid_key · key_revoked | no key, wrong key, or a key replaced by a newer one |
402 | no_credit | out of credit; add credit and retry |
403 | content_blocked | refused by the content policy |
404 | not_found | unknown endpoint |
413 | request_too_large | body over 8 MB |
429 | rate_limited · concurrency | over 300/min or 8 parallel — back off and retry |
503 | upstream_busy | temporary overload, retry shortly |
Questions and answers
How does the prepaid credit work?
Credit is charged based on real token usage for input and output. Errors and refusals do not consume credit. You can top up by crypto (USDT on TRC20, USDC on Base) for amounts between $20 and $500. Credit never expires, so you can use it whenever needed.
What is the difference between this and other LLM APIs?
We offer a single, uncensored open-weight model with transparent prepaid pricing. Unlike aggregators, we do not route between multiple vendors. Our model is tuned to answer without content refusals for lawful adult use. It is not GPT, Claude, or Llama.
Can I use JSON mode with streaming?
Yes, you can set response_format to json_object. When streaming, you must handle the final chunk to ensure you have the complete JSON object. Partial chunks may contain incomplete JSON. The final chunk also includes the token usage data.
Your key is one form away
Create an account, copy the key, change the base URL. That is the whole setup.