Grok limity API: Quickstart Guide
Use our OpenAI-compatible API to send uncensored text to a single model without corporate subscriptions or monthly fees. This guide shows how to authenticate, stream responses, and handle errors with zero training on your data.
Authentication & Base URL
Start by setting your API key and base URL in your client configuration. Our service uses standard headers, so you can swap in your existing OpenAI SDK settings without rewriting your logic. You receive one active key per account, which you can regenerate instantly if compromised. The base URL is HTTPS://api.groklimity.com/v1 and requires no special middleware. Remember that your prompt data is not used for training, ensuring privacy for your proprietary prompts.
Sending Your First Request
Send a POST request to /v1/chat/completions with the model ID uncensored. This endpoint accepts standard parameters like temperature and stop sequences. You can test the connection with a simple system message to verify latency. Errors like 401 indicate an invalid key, while 402 means your prepaid credit is exhausted. Note that the context window spans 100,000 tokens for both input and output combined.
curl https://api.groklimity.com/v1/chat/completions \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "uncensored",
"messages": [{"role": "user", "content": "Fix the syntax error in the loop."}]
}'
Python SDK Integration
Install the official openai package and point it to our base URL. This allows you to use familiar Python methods for synchronous or asynchronous calls. Set the model to uncensored to ensure you are hitting the correct endpoint. You can pass a list of messages just like you would with GPT-4. The library handles token counting automatically, so you stay aware of your usage limits. Tip: use max_tokens to cap output and avoid unexpected credit drain.
from openai import OpenAI
client = OpenAI(base_url="https://api.groklimity.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 SDK Configuration
Initialize the client with your API key and the custom base URL. Node developers can leverage the standard chat.completions.create method. This approach works seamlessly with existing projects that already use OpenAI clients. You do not need to rewrite your request structures. The SDK manages the HTTP connection and parses JSON responses efficiently. Warning: if you do not set max_tokens, the default output is capped at 2,048 tokens.
import OpenAI from "openai";
const client = new OpenAI({ baseURL: "https://api.groklimity.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 Responses
Enable streaming by setting stream: true in your request body. This returns a Server-Sent Events (SSE) stream of partial tokens. You can render text in real-time as it generates, improving perceived latency for users. The final chunk contains the total token usage statistics for billing. This method is ideal for chat interfaces where users expect immediate feedback. Requirement: ensure your client handles SSE events correctly to avoid memory leaks.
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)
Limits, Errors & Context
Each key allows 300 requests per minute and 8 concurrent requests. If you exceed this, you receive a 429 rate limit error. Request bodies are capped at 8 MB, which fits most standard conversation histories. Errors are free, so failed requests do not consume your prepaid credit. The model supports function calling and JSON mode for structured outputs. Constraint: only one active key exists per account, so rotate keys carefully.
FAQ
Is grok uncensored reliable for code generation?
The model handles code tasks effectively but is not Claude or Gemini. It excels in general text tasks and offers a cost-effective alternative for heavy usage. Test it with your specific codebase to verify output quality.
How does the prepaid credit system work?
You pay only for what you use, with no monthly subscriptions. Credits never expire, and you can top up via crypto with bonuses for larger amounts. Errors and refusals do not consume your credit, so you only pay for successful completions.
Can I use this as a grok API key replacement?
Yes, it is an OpenAI-compatible API that accepts the same client code. You just need to update the base URL and model ID. It runs a distinct uncensored model on our servers, not the official Grok service.