Uncensored Image Generator Text API Documentation
This guide shows how to integrate the uncensored text engine into your image generation pipeline for prompt engineering, captioning, and metadata extraction.
Base URL & Authentication
Every request to the unfiltered image generator API requires a valid API key passed in the Authorization header. The base URL is fixed at https://api.unfilteredimagegenerator.cc/v1. This URL works with the official OpenAI SDKs and any OpenAI-compatible client by updating the base_url configuration. Your key is generated immediately after signing up with Google or email on the key page. There is no phone number verification required, and the key is shown once. Keep it secure, as it grants access to your prepaid credit. If you lose it, generate a new key from the dashboard; the old key stops working immediately. This setup ensures your text pipeline remains reliable without unexpected content refusals during prompt generation.
First Request
Send a standard chat.completions request to generate text. Use the model ID uncensored to access the open-weight model tuned for lawful adult and controversial topics. The API accepts standard parameters like temperature, top_p, and stop. Responses are returned in JSON format. Errors are handled via standard HTTP status codes. This endpoint is the core of your text pipeline, allowing you to extract captions or write scripts for your images. Remember, this is a text-only API; it does not generate images, audio, or video itself.
curl https://api.unfilteredimagegenerator.cc/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."}]
}'
Python SDK Integration
Use the official openai Python package to interact with the API. Initialize the client with your API key and the specific base URL. The uncensored model ID ensures you get the expected uncensored responses. You can stream responses or retrieve them as standard objects. This approach is ideal for backend services that process large batches of image metadata. The library handles JSON parsing and error retries automatically. Ensure your environment has the openai package installed. This method is robust for production environments where reliability is critical.
from openai import OpenAI
client = OpenAI(base_url="https://api.unfilteredimagegenerator.cc/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
The Node.js SDK follows the same pattern. Install the openai package and configure the client with your key and base URL. Use the uncensored model ID for requests. This is useful for serverless functions or web servers that need to generate prompts on the fly. The SDK supports both synchronous and asynchronous calls. You can pass custom headers if needed, though the standard configuration is sufficient for most use cases. Errors are thrown as standard JavaScript errors, which you can catch and handle appropriately. This integration is straightforward and fits well into existing JavaScript pipelines.
import OpenAI from "openai";
const client = new OpenAI({ baseURL: "https://api.unfilteredimagegenerator.cc/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 (SSE)
Enable streaming by setting stream: true in your request. The API returns Server-Sent Events (SSE) as tokens are generated. This reduces perceived latency for long text outputs. The final chunk contains the total token usage for billing. Streaming is ideal for real-time captioning or interactive prompt editing. It allows you to display partial results to users immediately. Ensure your client handles SSE correctly. The uncensored model supports streaming efficiently. This feature is critical for applications where speed matters, such as live image analysis pipelines.
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 & Error Handling
Each API key is limited to 300 requests per minute and 8 concurrent requests. The request body must not exceed 8 MB. If you exceed these limits, the API returns a 429 status code. Authentication errors return 401, indicating an invalid or missing key. Payment errors return 402, meaning you need to top up your credit. The context window is 100,000 tokens total, with no separate output cap. If you do not set max_tokens, the response can run to the end of the window. Errors and refusals are free, so you only pay for successful token generation. Monitor your usage via the dashboard to avoid service interruptions.
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 |
|---|---|
| Compatibility | OpenAI Chat Completions schema; official openai SDKs work unchanged |
| Model ID | uncensored |
| API key | Bearer token in the Authorization header |
| Methods | POST /v1/chat/completions · GET /v1/models |
| Base URL | https://api.unfilteredimagegenerator.cc/v1 |
| Function calling | Yes — tools, tool_choice; replies carry tool_calls, also when streaming; send results back as role: tool |
| JSON mode | response_format: {"type": "json_object"} |
| Max context | 100,000 tokens, input and output combined |
| Max output | prompt + completion fit within 100,000 tokens; max_tokens optional, no separate output cap |
| Streaming | Supported (stream: true), usage included at the end |
| Sampling parameters | temperature, top_p, stop, seed, presence_penalty, frequency_penalty |
| Headers | X-Request-Id, X-Balance-USD, X-RateLimit-Limit-Requests, X-RateLimit-Limit-Concurrency |
| Requests per minute | 300/min per key |
| Concurrency | up to 8 in parallel per key |
| Request size | 8 MB request body |
| Trial credit | $0.50 for 7 days, no card · Trial key: 2 parallel requests, 60 req/min; full limits (8 and 300) after first top-up |
| Subscription | no monthly fee; paid credit does not expire |
| Billing | prepaid credit, charged by real token usage; errors and refusals are free |
| Volume bonus | +5% from $50, +10% from $100, +15% from $200 |
| Top-up | USDT (TRC20) or USDC (Base), any whole amount from $20 to $500 |
| Price | $0.15 per 1M input tokens · $0.50 per 1M output tokens |
| Keys | one active key per account; a new key replaces the old one |
| Sign-in | sign in with Google or with e-mail + password |
| Content | adult content allowed; sexual content involving minors is refused |
HTTP errors
Every error is JSON with a type you can switch on. You are never charged for an error.
| Code | Type | Meaning |
|---|---|---|
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 | check the Authorization header or use your current key |
402 | no_credit | balance is empty — top up, requests resume at once |
403 | content_blocked | refused by the content policy |
404 | not_found | unknown endpoint |
413 | request_too_large | request body larger than 8 MB |
429 | rate_limited · concurrency | slow down: rate or parallel limit reached |
503 | upstream_busy | temporary overload, retry shortly |
Questions and answers
Is the uncensored model the same as GPT-4?
No, it is an open-weight model run on our own servers, tuned for lawful adult use. It is not GPT, Claude, Gemini, Grok, DeepSeek, Qwen, or Llama. It answers without content refusals for specific use cases.
How do I pay for the API?
You can top up with USDT (TRC20) or USDC (Base). Any whole amount from $20 to $500 is accepted. You can also start with a free $0.50 trial credit for new accounts. Claim this credit with one click on your API key page. Credit never expires.
What happens if I send a request with sexual content involving minors?
This is a hard content limit that always applies. Requests containing sexual content involving minors will be refused, even though the model is uncensored for other lawful adult content.
Your key is one form away
Create an account, copy the key, change the base URL. That is the whole setup.