Get API key

Unrestricted AI API Quickstart Guide

Get started with the Unrestricted AI API by authenticating with your key and sending requests to our OpenAI-compatible endpoint. This guide covers basic usage, streaming, function calling, and critical limits for integrating our uncensored LLM into your application.

base_url
https://api.unrestrictedai.cc/v1
model
uncensored

Authentication and Base URL

The Unrestricted AI API uses standard OpenAI-compatible authentication. Include your API key in the Authorization header as a Bearer token. Your base URL is https://api.unrestrictedai.cc/v1. This setup works with any official OpenAI SDK or compatible client by simply updating the base URL and API key variables. We serve a single open-weight model tuned for uncensored responses, eliminating the complexity of model routing. There is no web chat UI; this is a pure API for developers. Sign up via Google or email to receive your key immediately. The key is tied to one account, and generating a new key replaces the old one. Keep your key secure, as it controls your prepaid credit usage.

Basic Chat Request

Send text conversations using the POST /v1/chat/completions endpoint. The model ID is always uncensored. You can send system, user, and assistant messages to guide the model's behavior. The model does not refuse lawful adult, fictional, or controversial topics, making it suitable for raw content generation. Note that we do not offer embeddings, image, or audio generation. Requests are charged based on token usage, with errors and refusals being free. Use the following example to send a simple message to the API.

Python SDK Integration

Integrate the API into your Python applications using the official OpenAI SDK. Install the package and configure the base URL to point to our servers. This allows you to use familiar Pythonic patterns for chat completions. The SDK handles tokenization and request formatting automatically. Ensure you set the model parameter to uncensored to use our specific uncensored model. This approach minimizes boilerplate code while maintaining full control over parameters like temperature and top_p. The SDK supports both synchronous and asynchronous operations for flexible deployment.

Node SDK Integration

For JavaScript and TypeScript projects, use the OpenAI Node SDK. Configure the base URL to our API endpoint and set your API key. This enables seamless integration into Node.js applications, Express servers, or serverless functions. The model ID remains uncensored across all requests. You can leverage existing OpenAI client code by simply swapping the base URL. This ensures compatibility with the broader ecosystem while providing access to our uncensored model. The SDK manages connection pooling and retry logic efficiently for high-throughput applications.

Streaming Responses

Enable real-time token generation by setting stream: true in your request. The API returns a Server-Sent Events (SSE) stream, allowing you to process tokens as they are generated. This reduces perceived latency for end-users. Each chunk contains partial content, and the final chunk includes token usage statistics. Streaming is ideal for chat interfaces where immediate feedback is required. The model supports streaming for all standard chat requests, including those with function calling or JSON formatting. Monitor the stream for completion to ensure the full response is received.

Limits, Errors, and Context Window

The API supports a 64,000-token context window (prompt + completion combined) with a maximum output of 16,000 tokens per request. If max_tokens is unset, the limit defaults to 2,048 tokens. You are limited to 300 requests per minute and 8 concurrent requests per key. Request bodies must not exceed 8 MB. Common errors include 401 for invalid keys, 402 for insufficient credit, and 429 for rate limits. Errors are free, so you can retry without cost. The context window is shared between input and output, so plan your prompt length accordingly to avoid truncation.

cURL

curl https://api.unrestrictedai.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

from openai import OpenAI

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

import OpenAI from "openai";

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

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)

Questions and answers

How do I top up my credit?

Top up using only crypto: USDT (TRC20) or USDC (Base). Accepted amounts are whole dollars from $10 to $500. You receive a 5% bonus for $50+ and 10% for $100+. Cards, PayPal, and bank transfers are not supported.

Is the trial credit renewable?

No. Each new account receives $0.50 in trial credit valid for 7 days. This is a one-time offer per person, with no credit card required. After the trial expires, you must top up with crypto to continue using the API.

Are prompts used for training?

No. Your prompts are not used for training purposes. We maintain a privacy-first approach, ensuring your data remains private. Only your email is required for account creation, and no phone number is needed.

Your key is one form away

Create an account, copy the key, change the base URL. That is the whole setup.