cursorapikey.com/Docs
Quickstart for Cursor users
Connect your coding tools to the uncensored API by updating your base URL and authentication headers. This quickstart covers the essential configurations for Cursor and other OpenAI-compatible agents.
Base URL and Authentication
Configure your client to point at https://api.cursorapikey.com/v1. The service expects standard OpenAI authentication headers. Generate your key on the Get API key page; you will need it for every request. Use the model ID uncensored to access the single available model. This setup works with any OpenAI-compatible SDK or agent like Cursor, Claude Code, or GitHub Copilot custom endpoints.
First Request
Test connectivity with a simple chat completion. The endpoint supports standard request bodies. If you receive a 200 status, your configuration is correct. A 401 error indicates an invalid or missing key, while a 402 error means your prepaid credit is exhausted.
curl https://api.cursorapikey.com/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."}]
}'
Requests exceeding 8 MB or 300 requests per minute may return specific error codes. Check the rate limit section for details.
Python SDK Integration
Use the official OpenAI Python library. Set the base URL and API key in your client initialization. The model ID remains uncensored. This approach works for local scripts or agent integrations that require programmatic API access. Ensure your library version supports the required OpenAI API structures.
from openai import OpenAI
client = OpenAI(base_url="https://api.cursorapikey.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)
Remember that prompts are not used for training. Your code context remains private to the request.
Node SDK Integration
Initialize the OpenAI Node.js client with the custom base URL. Pass the API key from your environment variables. The model ID uncensored is required for all completions. This setup is ideal for Node-based agents or serverless functions requiring consistent AI assistance.
import OpenAI from "openai";
const client = new OpenAI({ baseURL: "https://api.cursorapikey.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);
Verify your credentials before making bulk requests to avoid unnecessary 402 errors.
Streaming Responses
Enable streaming by setting stream: true in your request body. The API returns Server-Sent Events (SSE). This allows your UI or agent to process tokens as they are generated. Streaming reduces perceived latency for large responses. Ensure your client handles partial chunks correctly.
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)
Each chunk contains partial content. Aggregate these to form the final response.
Limits, Errors, and Context
The context window is 100,000 tokens for prompt and completion combined. Rate limits are 300 requests per minute per key. If you regenerate your key, the old one is revoked immediately. A 401 error indicates an invalid key. A 402 error indicates insufficient credit. A 429 error indicates rate limit exceeded. Credit never expires. Top-up options include crypto (USDT or USDC).
Under the hood: specs
One table with every limit, feature and price that applies to your key.
| Feature | Support |
|---|---|
| API format | OpenAI Chat Completions schema; official openai SDKs work unchanged |
| Model | uncensored |
| API key | Bearer token in the Authorization header |
| Base URL | https://api.cursorapikey.com/v1 |
| Methods | POST /v1/chat/completions · GET /v1/models |
| Other parameters | temperature, top_p, stop, seed, presence_penalty, frequency_penalty |
| Structured output | response_format: {"type": "json_object"} |
| Max output | 16,000 tokens max; 2,048 if max_tokens is not set |
| Context window | 100,000 tokens, input and output combined |
| Function calling | Supported: tools + tool_choice, tool_calls in the reply (streamed too), tool results as role: tool messages |
| Streaming | Yes — server-sent events; the last chunk carries token usage |
| Request size | up to 8 MB per request |
| Parallel requests | 8 requests at the same time per key |
| Rate limit | 300 requests per minute per key |
| Headers | X-Request-Id, X-Balance-USD, X-RateLimit-Limit-Requests, X-RateLimit-Limit-Concurrency |
| Token prices | $0.25 per 1M input tokens · $1.00 per 1M output tokens |
| Free trial | $0.50 of credit valid 7 days, no card needed |
| Bonus credit | +5% from $50, +10% from $100 |
| Credit expiry | paid credit never expires, no subscription |
| Top-up | crypto: USDT on TRON or USDC on Base, $10–$500, any whole sum |
| How you pay | pay as you go from prepaid credit; nothing is charged for failed or refused requests |
| Sign-in | sign in with Google or with e-mail + password |
| Key management | one key per account, regenerate any time (the old one stops working) |
| Content policy | adult content allowed; sexual content involving minors is refused |
When a request fails
The type field is stable, the message is for humans. Errors cost nothing.
| HTTP | Type | What to do |
|---|---|---|
400 | bad_request | invalid JSON, empty messages, bad parameter, or prompt + max_tokens over the window — fix and resend |
401 | missing_key · invalid_key · key_revoked | no key, wrong key, or a key replaced by a newer one |
402 | no_credit | balance is empty — top up, requests resume at once |
403 | content_blocked | sexual content involving minors — refused, not billed |
404 | not_found | only /v1/chat/completions and /v1/models exist |
413 | request_too_large | request body larger than 8 MB |
429 | rate_limited · concurrency | slow down: rate or parallel limit reached |
503 | upstream_busy | model busy — retry in a few seconds |
Questions and answers
Is this the official Cursor API?
No, this is an independent service. It is OpenAI-compatible and works as a custom endpoint in Cursor and similar tools. It is not affiliated with Cursor, OpenAI, or Anthropic.
What happens if I exceed the rate limit?
Requests exceeding 300 per minute will return a 429 error. The limit is per key. Regenerating your key revokes the old one but does not reset the rate limit window for the new key.
How do I top up my account?
You can top up from $10 using crypto (USDT or USDC). Bonus credit is available: +5% from $50 and +10% from $100. Paid credit never expires.
Your key is one form away
Create an account, copy the key, change the base URL. That is the whole setup.