Integrating an Uncensored Text API: A Developer Checklist
Building a text-based application that requires long-term context and minimal guardrails demands careful integration. This checklist guides you through setting up an OpenAI-compatible endpoint to ensure consistent outputs for roleplay or creative writing workflows.

Understanding the Model and Context Window
When integrating an uncensored text API, the first step is selecting the correct model identifier. Our service provides a single, open-weight text model identified by the string "uncensored." This model is designed to generate text with minimal refusal on lawful adult, fictional, or controversial topics, making it suitable for creative writing and roleplay applications. The model accepts text input and returns text output, ensuring a straightforward integration path for developers familiar with standard chat completions.
A critical factor for maintaining narrative consistency is the context window. Our API supports a context window of 100,000 tokens, which includes both the prompt and the completion. This large window allows your application to retain long conversation histories or detailed story plots without losing context. For developers building roleplay bots or long-form document generators, this capacity ensures that earlier details remain accessible throughout the session.
To utilize this capacity effectively, you must manage the token budget carefully. The context window is shared between your input and the model's output. If your application sends long prompts, the remaining space for the model's response decreases. Therefore, it is essential to monitor token usage and truncate older messages if necessary to stay within the limit. This approach helps maintain a smooth user experience without unexpected errors due to context overflow.
Unlike services that offer multiple models or specialized endpoints for embeddings and image generation, our API focuses solely on text generation. This simplicity reduces complexity in your integration code. You do not need to handle different model routing logic or manage separate endpoints for different data types. The focus remains on delivering high-quality text outputs that respect the uncensored nature of the model while providing the context depth required for complex interactions.
Setting Up the Endpoint and Authentication
Integrating with our API begins with understanding the base URL and endpoints. The base URL for our service is https://api.grokapi.cc/v1. You will interact with three primary endpoints: POST /v1/chat/completions for generating text, POST /v1/responses for alternative response formats, and GET /v1/models to verify available models. These endpoints follow the standard OpenAI-compatible format, which means you can likely use existing SDKs with minimal modification.
Authentication is handled via an API key, which you receive immediately after signing up. You can sign up using Google or by creating an account with an email and password. The key is displayed right away, allowing you to start testing without delay. It is important to store this key securely in your application environment variables. The API uses this key to identify your account and track your prepaid credit usage.
When making requests, ensure you include the API key in the authorization header. This ensures that your requests are authenticated and billed correctly against your prepaid balance. The API returns specific error codes to help you troubleshoot issues. A 401 error indicates an invalid key, a 402 error means you have no credit, and a 429 error signals that you have hit the rate limit.
Rate limiting is enforced at 300 requests per minute per key. This limit is generous for most use cases but should be considered when designing your application's request logic. If you are building a high-throughput application, you may need to implement backoff strategies or queue requests to avoid hitting the limit. Understanding these limits helps you design a reliable integration that handles network variability and peak usage efficiently.
Configuring Parameters for Consistent Outputs
To achieve consistent and high-quality text outputs, you should configure the available parameters in your API requests. Our API supports standard parameters such as temperature, top_p, stop sequences, seed, and penalties. These parameters allow you to control the randomness and style of the model's responses. For example, setting a lower temperature can produce more deterministic outputs, which is useful for tasks requiring precision.
The seed parameter is particularly useful for reproducible results. By setting a specific seed, you can ensure that the same input produces the same output, which is valuable for testing and debugging your integration. This feature allows you to verify that your prompt engineering changes have the desired effect without the variability introduced by randomness. It helps in creating a stable environment for evaluating model performance.
Stop sequences allow you to define specific strings that signal the end of a response. This is useful for controlling the length of the output or stopping the model at a specific point in a narrative. For instance, you might use a stop sequence to end a response when a character finishes speaking. This gives you more control over the structure of the generated text and prevents the model from continuing beyond your intended boundary.
Penalties help manage the frequency and presence of tokens in the output. By adjusting these penalties, you can influence the model's tendency to repeat phrases or introduce new topics. This is particularly important in roleplay scenarios where you want to maintain a consistent voice and avoid repetitive dialogue. Fine-tuning these parameters allows you to tailor the model's behavior to your specific application needs.
Handling Streaming and Function Calling
For applications that require real-time feedback, our API supports streaming over Server-Sent Events (SSE). Streaming allows you to receive the model's response incrementally as it is generated, rather than waiting for the entire response to complete. This improves the user experience by providing immediate feedback and reducing perceived latency. The usage information, such as token counts, is included in the last chunk of the stream, allowing you to track costs accurately.
In addition to streaming, the API supports function calling, also known as tools. This feature allows the model to call specific functions defined by your application, enabling it to interact with external systems or perform actions based on the conversation. For example, the model might call a function to fetch data from a database or update a user's profile. This capability expands the utility of the API beyond simple text generation, allowing for more complex and interactive applications.
JSON mode is another valuable feature for developers who need structured output. By enabling JSON mode, you can ensure that the model's response is formatted as valid JSON, which simplifies parsing and integration with your application's backend. This is particularly useful for applications that require structured data for further processing or display. It reduces the need for additional parsing logic and ensures consistency in the data format.
When implementing streaming and function calling, it is important to handle potential errors and edge cases. For instance, if a function call fails, your application should have a fallback mechanism to handle the error gracefully. Similarly, if the stream is interrupted, you should be able to resume or retry the request. These considerations help ensure a smooth and reliable user experience, even in the face of network issues or unexpected model behavior.
Managing Credits and Pricing
Our API uses a prepaid credit system, which means you pay for what you use without any monthly subscription fees. The pricing is $0.15 per 1 million input tokens and $0.50 per 1 million output tokens. This transparent pricing model allows you to control costs based on actual usage. Errors and refusals are free, so you only pay for successful token generation. This can be beneficial for applications with variable usage patterns.
Top-ups are accepted only via cryptocurrency, specifically USDT on the TRC20 network or USDC on the Base network. You can top up with any whole amount between $20 and $500. Additionally, there is a bonus credit program for top-ups of $50 or more, which offers a bonus ranging from 5% to 15%. This bonus can help you get more value from your purchases and reduce the effective cost per token.
It is important to note that paid credit never expires, so you can top up whenever it is convenient and use the credits over time. This flexibility allows you to manage your budget effectively without the pressure of expiring balances. However, since payments are crypto-only, you need to ensure that your application or billing system can handle cryptocurrency transactions. This might involve integrating with a crypto payment gateway or using a wallet for manual top-ups.
New accounts receive $0.50 of trial credit, which allows you to test the API without needing to add a card or make a payment. This trial credit is a great way to explore the API's capabilities and verify that it meets your needs before committing to a larger top-up. It provides a risk-free way to evaluate the model's performance and integration ease.
When Our API Is Not the Right Choice
While our API is well-suited for text generation with minimal guardrails, it may not be the right choice for all applications. For instance, if your project requires image, audio, or video generation, our API does not support these modalities. It is a text-only service, so you would need to integrate with other providers for multimedia capabilities. Similarly, if you need embeddings for vector search, our API does not currently offer this feature.
Applications that require fine-tuning models to specific datasets will also find our API limited. We do not offer fine-tuning capabilities, so you would need to use a different service if you need to customize the model's behavior through training. Additionally, if you need model routing to switch between different models based on the task, our API serves only one uncensored model, so this feature is not available.
OCR and document processing are other areas where our API does not provide functionality. If your application needs to extract text from images or process documents, you would need to use a separate OCR service. The API focuses solely on text generation, so it is not a comprehensive solution for all AI needs. Developers should evaluate their specific requirements to determine if our API fits their use case.
Finally, if you require an SLA guarantee or certifications such as SOC2, HIPAA, or ISO, our API does not currently offer these. We are an independent service and do not make claims about uptime percentages or compliance certifications. If these are critical for your application, you may need to choose a provider that offers these assurances. Understanding these limitations helps you make an informed decision about whether our API is the best fit for your project.
Addressing Developer Needs from Reddit Discussions
Developers on Reddit often discuss the need for a Grok alternative that can handle long messages, maintain plot continuity, and manage details in roleplay scenarios. They frequently mention the desire for a model with little to no guardrails, especially for creative writing and adult content. Our API addresses these needs by providing an uncensored model that does not refuse lawful adult or controversial topics, allowing for more freedom in content generation.
Users also express frustration with guardrails increasing on other platforms, which can disrupt the user experience in roleplay applications. Our service offers a stable environment with consistent behavior, as the model does not change its refusal criteria frequently. This stability is important for developers who want to build reliable applications that users can trust to maintain the narrative flow without unexpected interruptions.
Another common theme in Reddit threads is the need for document generation capabilities. While our API does not directly generate PDFs or Word documents, it can generate the text content that can be fed into a document generation tool. This separation of concerns allows developers to use our API for text generation and combine it with other tools for formatting and output. This approach provides flexibility and allows for customization based on specific document requirements.
Additionally, users discuss the importance of handling mistakes or incorrect assumptions in conversations. Our API's function calling feature can be used to implement logic that checks for errors or provides pushback when necessary. This allows developers to create more interactive and responsive applications that can adapt to user input and maintain a coherent dialogue. By using these features, developers can build applications that meet the diverse needs of their users.
Frequently asked questions
How do I sign up for the API?
You can sign up using Google or by creating an account with an email and password. Your API key is displayed immediately after signup, allowing you to start using the service right away without needing to add a credit card.
What payment methods are accepted?
We accept only cryptocurrency for top-ups: USDT on the TRC20 network or USDC on the Base network. You can top up with amounts between $20 and $500, and you may receive a bonus of 5% to 15% for top-ups of $50 or more.
Does the API support streaming?
Yes, the API supports streaming over Server-Sent Events (SSE). This allows you to receive the model's response incrementally, providing a better user experience by showing text as it is generated. Usage information is included in the final chunk of the stream.
What happens if I run out of credit?
If you run out of credit, the API will return a 402 error. You can top up your account with crypto to resume usage. Errors and refusals do not consume credit, so you only pay for successful token generation.