繁中 ▾

API 參考與快速入門

在數秒內取得您的無審查 LLM API 金鑰並立即開始發送請求。此快速入門指南涵蓋身份驗證、程式碼範例以及無審查 AI API 的速率限制。

https://api.uncensoredaipricing.com/v1uncensored

驗證與速率限制

在儀表板生成您的金鑰。無審查 AI API 使用標準的 bearer token 進行身份驗證。您每分鐘可獲得 300 次請求和 8 個並行連線。錯誤和拒絕不消耗信用額度。

將您的金鑰包含在標頭中。基礎 URL 為 HTTPS://api.uncensoredaipricing.com/v1。使用 Google 或電子郵件註冊。無需電話號碼。

聊天完成端點

透過 POST /v1/chat/completions 將文字傳送至無審查 LLM API。模型 ID 為「uncensored」。它在 100,000 個 token 的上下文視窗內處理提示與補全。最大輸出為 16,000 個 token。

設定 API 金鑰。以下是 curl 範例:

curl https://api.uncensoredaipricing.com/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "uncensored",
    "messages": [{"role": "user", "content": "Calculate the monthly cost for 50 million tokens."}]
  }'

串流回應 (SSE)

透過伺服器發送事件 (Server-Sent Events) 接收即時 token。串流可降低長回應的感知延遲。在請求中使用 stream 參數。最後一個區塊包含最終的 token 用量。

這是一個 Python 範例:

from openai import OpenAI

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

JSON 模式與函式呼叫

使用 response_format 設為 json_object 強制執行結構化輸出。啟用使用工具和 tool_choice 的函式呼叫。temperature 和 top_p 等參數控制隨機性。使用 stop 序列進行乾淨的截斷。

這是一個 Node 範例:

import OpenAI from "openai";

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

Token 限制與上下文視窗

上下文窗口總計 100,000 token。超過 8MB 或 300 RPM 的請求將被拒絕。設定 max_tokens 為 16,000。預設為 2,048。預付信用額度永不過期。錯誤免費。

這是一個串流範例:

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)

錯誤代碼 & 拒絕行為

401 表示金鑰無效。402 表示沒有額度。429 表示速率限制。未成年人色情內容會觸發硬性拒絕。其他成人內容則會通過。請檢查狀態碼。修正您的金鑰或充值。

常見問題

什麼是 uncensored AI 定價?

每 1M 輸入 token 費用為 $0.15,每 1M 輸出 token 費用為 $0.50。預付信用額度根據實際用量計費。錯誤與拒絕請求免費。無月費。

如何取得無審查 AI 的 API 金鑰?

在金鑰頁面使用 Google 或電子郵件註冊。金鑰會立即顯示。無需電話號碼。您將獲得有效期為 7 天的 $0.50 試用信用額度。

上下文視窗的大小是多少?

總上下文視窗為 100,000 個 token。此包含 prompt 與 completion。每次請求的最大輸出為 16,000 個 token。預設輸出為 2,048 個 token。

取得您的 API 金鑰

註冊,複製金鑰,更新端點。只需這樣即可。

使用試用信用額度嘗試