EN ▾
  1. MiniMax Uncensored
  2. Uncensored AI API Quickstart Guide

Uncensored AI API Quickstart Guide

Get started with the uncensored AI API in minutes using standard OpenAI-compatible code. This guide covers authentication, endpoints, and streaming for your first request.

Base URL and Authentication

The uncensored LLM API lives at https://api.minimaxuncensored.com/v1. Authenticate by passing your API key in the Authorization header. Every request requires this header to identify your account and track token usage against your prepaid balance.

  • Base URL: https://api.minimaxuncensored.com/v1
  • Header: Authorization: Bearer YOUR_API_KEY

Supported Endpoints: /v1/chat/completions

We support only POST /v1/chat/completions and GET /v1/models. No embeddings, images, or fine-tuning endpoints exist here. This simplicity ensures predictable behavior for uncensored content generation without routing complexity.

Send your conversation history as a JSON array of messages. The API returns text completions that respect your model configuration.

Model ID and Configuration

Set the model ID to uncensored in your requests. This specific open-weight model runs on our servers and does not refuse lawful adult, fictional, or controversial topics. It is not GPT, Claude, or any other vendor's model.

Configure parameters like temperature and top_p to control creativity. The context window supports 100,000 tokens total for prompt and completion combined.

Parameters: Temperature, Top-P, and JSON Mode

Use temperature to adjust randomness and top_p for nucleus sampling. Enable JSON mode by setting response_format to {"type": "json_object"}. This forces structured output for programmatic use cases.

Other supported parameters include stop, seed, presence_penalty, and frequency_penalty. These allow fine-tuning of the generation style.

Streaming Responses and Token Usage

Enable streaming by setting stream: true in your request body. The API returns Server-Sent Events (SSE) containing partial tokens. Token usage statistics appear in the final chunk of the stream.

This approach reduces perceived latency for long uncensored responses. It is ideal for real-time applications requiring immediate text delivery.

Limits, Errors, and Context Window

You are limited to 300 requests per minute and 8 concurrent requests per key. The maximum request body size is 8 MB. Errors like 401 indicate an invalid key, while 402 means no prepaid credit remains. Refusals due to credit exhaustion are free.

The context window is 100,000 tokens. Max output is 16,000 tokens per request. Exceeding these limits results in 429 rate limit errors.

cURL

curl https://api.minimaxuncensored.com/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "uncensored",
    "messages": [{"role": "user", "content": "List the main differences between python 3 and python 2"}]
  }'

Python

from openai import OpenAI

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

Node.js

import OpenAI from "openai";

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

Streaming

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)

FAQ

What is the base URL for the uncensored AI API?

The base URL is HTTPS://api.minimaxuncensored.com/v1. It works with any OpenAI-compatible SDK by updating the base_url configuration.

How do I authenticate with the uncensored LLM online service?

Include your API key in the Authorization header as a Bearer token. No phone number or additional verification is required after signup.

What happens if I exceed the rate limit?

You will receive a 429 Too Many Requests error. The limit is 300 requests per minute and 8 concurrent requests per API key.

Generate your API key

Register, retrieve your key, and update your base URL. Done.

Get your key