EN ▾

Uncensored. Compliant. Developer-First.

Quickstart: unfiltered ai model integration

Integrate the unfiltered AI model into your applications using our OpenAI-compatible API. This guide walks you through authentication, making requests, and handling streaming responses with concrete examples.

Prerequisites: SDK installation and environment setup

The unfiltered AI model works with standard OpenAI SDKs. You need an API key from the dashboard and the base URL HTTPS://api.unfilteredaimodel.com/v1. Install the library for your preferred language to handle authentication headers automatically.

Set the environment variable or pass the key directly in your client initialization. The model id is "uncensored". No other configuration is required for basic text generation.

  • Install the package via npm, pip, or your package manager.
  • Ensure you have a valid API key from the dashboard.
  • Verify the base URL matches the provided endpoint.

Initialize the client with your base URL and key

Configure the client to point to our base URL and use your API key for authentication. This ensures all requests are routed to the uncensored model correctly.

  • Set the base URL to HTTPS://api.unfilteredaimodel.com/v1
  • Pass your API key in the authorization header
  • Specify the model id as "uncensored"

This setup works with any OpenAI-compatible client. You can use the official SDKs or any library that supports the OpenAI API format.

curl https://api.unfilteredaimodel.com/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "uncensored",
    "messages": [{"role": "user", "content": "What is the capital of France?"}]
  }'

Sending your first chat completion request

Send a POST request to /v1/chat/completions with your messages array. The model will respond with generated text without content refusals for lawful adult use.

  • Use the messages parameter to define the conversation
  • Specify the model as "uncensored"
  • Set the temperature and other parameters as needed

The response will contain the generated text in the choices array. You can extract the content and use it in your application.

from openai import OpenAI

client = OpenAI(base_url="https://api.unfilteredaimodel.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)

Handling streaming responses and token usage

Enable streaming by setting stream=true in your request. The API returns chunks of text as they are generated. Token usage is reported in the last chunk.

  • Set stream=true in the request body
  • Process each chunk as it arrives
  • Check the last chunk for token usage

This is useful for real-time applications where you want to display text as it is generated. The streaming response includes token counts for billing transparency.

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)

Configuring temperature, top_p, and JSON mode

Customize the model's behavior using parameters like temperature, top_p, and response_format. These settings control creativity, randomness, and output format.

  • Adjust temperature for creativity (0.0 to 1.0)
  • Set top_p for nucleus sampling
  • Use response_format=json_object for structured output

The model supports function calling and tool use. You can define tools and let the model decide when to call them. This enables complex workflows and integrations.

import OpenAI from "openai";

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

Error handling and rate limits (300 RPM)

The API enforces a limit of 300 requests per minute per key. If you exceed this, you will receive a 429 error. Other common errors include 401 for invalid keys and 402 for insufficient credit.

  • Monitor your request rate to avoid 429 errors
  • Handle 401 errors by checking your API key
  • Handle 402 errors by topping up your credit

The context window is 100,000 tokens for prompt and completion combined. Max output is 16,000 tokens per request. Errors and refusals do not consume credit.

Frequently asked questions

How do I top up my credit?

You can top up your credit using USDT (TRC20) or USDC (Base). Minimum amount is $20, maximum is $500. Bonus credit is added for larger top-ups: +5% from $50, +10% from $100, and +15% from $200. Credit never expires.

What is the context window size?

The context window is 100,000 tokens for both prompt and completion combined. The maximum output per request is 16,000 tokens. If you do not set max_tokens, the default is 2,048 tokens.

Is the model truly uncensored?

The model does not refuse lawful adult, fictional, security-research, or controversial topics. The only hard content limit is sexual content involving minors, which is always refused. This makes it ideal for NSFW roleplay and raw model output.

Your API key is one step away

Sign up, retrieve your key, update the base URL. The entire process takes seconds.

Start now