EN ▾

Guide to groq api Keys

Unlock unrestricted text generation with our uncensored LLM API, designed for developers who need high-speed, OpenAI-compatible endpoints without content refusals or monthly subscriptions. We eliminate tiered limits by charging strictly for real token consumption via prepaid crypto credits, ensuring your projects scale without hidden fees or data training surprises.

Last updated

Why groq API Keys Matter

The primary value of a dedicated API key lies in isolating your production traffic from development noise while ensuring consistent access to uncensored generation capabilities. Unlike generic providers that filter content aggressively, our infrastructure serves a model tuned specifically for unrestricted outputs, meaning your prompts for NSFW themes, roleplay, or controversial topics return results without unnecessary refusals. This isolation is critical for applications where content policy drift could break user expectations or cause unexpected errors in downstream logic.

Our architecture eliminates the frustration of hitting arbitrary tier limits during peak usage. Instead of worrying about monthly quotas that reset unpredictably, you control your spending through prepaid credits. The key acts as a precise gatekeeper, allowing you to monitor exact token consumption and maintain budget stability without relying on complex rate-limiting logic in your application code.

Generating Your First groq API Key

Generating your key requires only a Google account or a simple email and password registration, with no phone number verification needed for immediate access. Upon signing up, you navigate to the 'Get API key' page where the system displays your unique identifier instantly, allowing you to copy it directly into your environment variables. This streamlined process ensures you can start testing within minutes rather than waiting for approval emails or manual verification steps.

Each account is restricted to one active key at a time to simplify security management; generating a new key automatically invalidates the previous one. This design prevents confusion when rotating credentials during deployment updates. You can generate a fresh key anytime if you suspect exposure, ensuring your uncensored LLM access remains secure without managing multiple legacy tokens for the same account.

Understanding Key Limits

Your API key enforces strict boundaries to ensure fair usage across our high-performance infrastructure: 300 requests per minute, 8 concurrent connections, and an 8 MB request body limit. These constraints are designed to prevent single users from monopolizing the GPU resources required for low-latency generation. If your application exceeds these thresholds, the API returns standard HTTP 429 or 413 errors, allowing your client code to implement exponential backoff strategies effectively.

Understanding these limits is crucial for scaling your deployment. For instance, if you are building a high-volume chatbot, you may need to implement request queuing on the client side rather than relying on the API to handle burst traffic. The 100,000 token context window allows for extensive conversation history, but each token counts toward your prepaid balance, so monitoring usage via the dashboard helps you anticipate when a top-up is needed before your credits deplete.

Integrating groq API Keys into Code

Integration is straightforward because our endpoint follows the standard OpenAI chat-completions protocol. You simply update the base URL to HTTPS://api.apigroq.com/v1 and pass your key in the Authorization header. This compatibility means you can use existing OpenAI SDKs for Python, Node.js, or other languages without rewriting your core inference logic. The model identifier is 'uncensored', which tells the server to serve the unrestricted large language model optimized for your specific content needs.

Our API supports streaming via Server-Sent Events (SSE), function calling, and JSON mode. These features allow you to build dynamic applications that process responses in real-time or extract structured data reliably. When using streaming, token usage details are included in the final chunk, enabling accurate billing tracking within your own application logic. This flexibility ensures that whether you are building a simple text generator or a complex agent, the key provides the necessary access points.

Billing and Usage Tracking

Billing is transparent and prepaid, with no monthly subscriptions or hidden fees. You are charged strictly for the tokens you consume: $0.15 per million input tokens and $0.50 per million output tokens. Errors and refusals do not incur charges, meaning you only pay for successful generation attempts. This model is particularly cost-effective for developers who want predictable costs without the risk of surprise bills from unexpected usage spikes.

Credits never expire, so you can top up infrequently without losing your balance. We track usage in real-time, allowing you to monitor your remaining credit through the dashboard. This visibility helps you manage your budget effectively, ensuring that your project continues to run smoothly even during periods of high traffic. The prepaid nature of the service also means you can stop using the API at any time without cancellation fees.

Security Best Practices

Since your API key grants access to your prepaid credits, treating it as a secret is paramount. Avoid committing the key directly to public repositories; instead, use environment variables or secret managers in your deployment pipeline. Because each account allows only one active key, you can easily rotate credentials if you suspect a leak by generating a new key from the dashboard, instantly invalidating the old one.

Our model does not use your prompts for training, ensuring that your proprietary data or unique roleplay scenarios remain private. However, the hard content limit applies universally: requests involving sexual content with minors are always refused, regardless of your credit balance. This ensures compliance with basic content standards while allowing broad freedom for other adult or controversial topics. Monitoring your key's usage patterns can also help you detect unauthorized access early.

Troubleshooting Key Errors

If you encounter an 'Invalid API Key' error, verify that you have copied the key correctly without extra spaces or line breaks. Since only one key is active per account, ensure you are not using an older key that was invalidated when you generated a new one. Check your internet connection and ensure that the base URL is correctly set to HTTPS://api.apigroq.com/v1, as incorrect endpoints are a common source of connection failures.

Rate limit errors (429) indicate you have exceeded the 300 requests per minute or 8 concurrent connections threshold. Implementing exponential backoff in your client code will handle these gracefully. If you see errors related to token limits, ensure your prompt plus completion does not exceed the 100,000 token context window. For other issues, the Support page can help resolve account-specific billing or access problems.

Top-Ups and Credit Management

Top-ups are processed exclusively via cryptocurrency, specifically USDT on the TRC20 network or USDC on the Base network. You can add any whole amount between $20 and $500 per transaction. To incentivize larger deposits, we offer bonus credits: +5% for deposits of $50, +10% for $100, and +15% for $200. This bonus credit is added to your balance immediately, extending the lifespan of your prepaid funds.

Credits do not expire, so you can top up at your convenience without worrying about losing your balance. If you make a mistake, such as a double charge, you can request a correction through the Support page. Your original credit remains intact, ensuring that your usage history is accurate. This flexibility allows you to manage your budget efficiently, topping up only when necessary.

Final Checklist for Production

Before deploying your application, verify that your API key is stored in environment variables and not hardcoded. Ensure your base URL is set to HTTPS://api.net/v1 and that you are using the model identifier 'uncensored'. Test your streaming implementation to confirm that token usage is captured correctly in the final chunk. Verify that your client code handles 429 rate limit errors with appropriate backoff strategies.

Confirm that your content filters align with the hard limit on minor sexual content. Ensure your billing settings are correct, with crypto payments configured for seamless top-ups. Finally, test your integration with the OpenAI SDK to ensure compatibility. This checklist ensures a smooth transition from development to production, leveraging the full power of our uncensored LLM API.

Frequently asked questions

Is the groq API free to use?

After the trial, you must top up with crypto (USDT or USDC) to continue using the API. There is no free tier, but you only pay for the tokens you actually consume.

What is the groq API pricing for tokens?

The pricing is $0.15 per million input tokens and $0.50 per million output tokens. Errors and refusals are free, so you only pay for successful generation attempts. This prepaid model ensures transparent costs without monthly subscriptions.

Does the API support streaming?

Yes, the API supports streaming via Server-Sent Events (SSE). Token usage details are included in the final chunk of the stream, allowing you to track consumption accurately in real-time. This feature is ideal for chatbots and dynamic applications.

How do I top up my credit?

Top-ups are processed exclusively via crypto: USDT on TRC20 or USDC on Base. You can deposit any whole amount from $20 to $500. Bonus credits are applied automatically based on the deposit amount, with up to 15% bonus for larger deposits.

Get your API key in minutes

Sign up, retrieve your key, and update your base URL. That is all the configuration required.

Get your key