OpenAI-Compatible API Documentation
Drop our uncensored model into your existing stack by swapping the base URL and API key. You get a direct OpenAI-compatible endpoint that processes text without content filters.
Quickstart: Connect with OpenAI SDK
Start by authenticating with your key and pointing the client to our base URL. This setup works with the official OpenAI SDKs for Python and Node.js, ensuring you can run the same client code against our service. You need a valid API key from the dashboard and the correct endpoint configuration.
curl https://api.openaiapicompatible.com/v1/chat/completions \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "uncensored",
"messages": [{"role": "user", "content": "Return the current UTC timestamp in ISO 8601 format"}]
}'from openai import OpenAI
client = OpenAI(base_url="https://api.openaiapicompatible.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)import OpenAI from "openai";
const client = new OpenAI({ baseURL: "https://api.openaiapicompatible.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);
Chat Completions Endpoint
Send text to our single chat endpoint for direct text output. We use POST /v1/chat/completions to process your prompts and return generated text. This is the core interaction for most LLM applications, requiring no complex routing or additional service calls.
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)
Streaming with SSE
Receive tokens in real-time using Server-Sent Events for lower latency. Enable streaming by setting the stream parameter to true in your request. The final chunk includes token usage data, allowing you to track costs accurately as the model generates text. This approach keeps your UI responsive even for long outputs.
Function Calling & JSON Mode
Integrate tools and enforce structured outputs for reliable programmatic interactions. Use the tools parameter to define function schemas and set response_format to json_object for strict JSON compliance. Our uncensored model handles complex instructions and edge cases without refusing valid functional requests.
Rate Limits & Parameters
Monitor your usage against strict per-key limits to avoid service interruptions. You are allowed 300 requests per minute and eight concurrent requests per key, with an 8 MB body limit. Errors like 401 (invalid key), 402 (no credit), and 429 (rate limit) indicate specific account states.
Context Window & Constraints
Maximize context handling with a 100,000-token window for combined input and output. Set max_tokens to control generation length, defaulting to 2,048 if unspecified. Our model runs on proprietary servers, not as a proxy for other vendors, ensuring consistent performance for your specific use case.
Common questions
Is this API compatible with OpenAI SDKs?
Yes, it is fully compatible with standard OpenAI client libraries. You simply update the base URL and API key in your configuration. This allows you to use existing code without major refactoring.
What happens if I hit the rate limit?
The API returns a 429 status code when you exceed 300 requests per minute or eight concurrent connections. Reduce your request frequency or distribute load across multiple keys if available.
Do you store my prompts for training?
No, your prompts are not used for training models. We prioritize privacy by keeping account data minimal and not retaining your input data for model improvement purposes.
Get your API key
Register, grab the key, swap the base URL. Done.