Inference APIs

Groq 400 organization_restricted: "Organization has been restricted"

Every call to Groq now fails with Error code: 400 - {'error': {'message': 'Organization has been restricted. Please reach out to support if you believe this was in error.', 'type': 'invalid_request_error', 'code': 'organization_restricted'}}. Despite the 400 and the invalid_request_error type, nothing is wrong with the request. Groq has locked the whole organization, so a different model, a new key or a retry will all return the same error. The way out is through Groq support. Your app can run elsewhere in the meantime.

Last verified November 30, 2026 against Groq billing FAQs, Groq API keys, Error body in a Hugging Face Space discussion · 5 min read

ProviderGroq
HTTP status400 Bad Request
Error type / codeinvalid_request_error / organization_restricted
MessageOrganization has been restricted. Please reach out to support if you believe this was in error.
ScopeThe whole organization: every key and every model, not one request
Usual causesAn automated terms-of-service flag, or a technical flag such as an API key detected in public
Can you wait it out?No. It stays until Groq support lifts it
Short answer
  • It is the account, not the request. All keys and all models in the organization return it. Stop retry loops.
  • Rotate your keys first. A key found in a public repo, Space or client bundle is one of the reasons Groq locks organizations.
  • Then email support@groq.com with your organization id and what the app does. There is no self-serve unlock.
  • While you wait: a legitimate app can send the same request, with the same model id, to another OpenAI-compatible provider.
Try it now: no account, no key

Send a prompt to openai/gpt-oss-120b (the same id you use on Groq) on a pay-per-request endpoint with no tier to unlock and see it answer here. Five free requests per day.

What the error means

Groq's API follows OpenAI's error format, which has no dedicated "account locked" status. It reports the lock as a 400 invalid_request_error with the code organization_restricted. The code is the useful part. It applies to the organization, the unit Groq bills and rate-limits by, so every key under it fails at once. That includes keys you create after the restriction.

What you might tryDoes it help?
Retry with backoffNo. The error is not transient
Create a new API keyNo. The lock is on the organization, not the key
Switch to another Groq modelNo. It applies to every model
Rotate keys, then contact supportYes. This is the only way to lift it
Open a new Groq accountDo not. Groq's terms forbid it, and a second account usually gets flagged the same way
Python · recognise the restriction and stop retrying
import groq

try:
    resp = client.chat.completions.create(model="openai/gpt-oss-120b", messages=messages)
except groq.BadRequestError as e:
    body = getattr(e, "body", None) or {}
    err = body.get("error", body) if isinstance(body, dict) else {}
    if err.get("code") == "organization_restricted":
        # Not a bad request and not transient: every call from this org fails until Groq lifts it.
        alert_ops("Groq organization restricted: rotate keys, then email support@groq.com")
        raise SystemExit(1)   # do not retry in a loop; it only adds failed calls to the account history
    raise

Why organizations get restricted

Groq does not publish a list of triggers, and the error does not say which one applied. Groq staff have pointed to two kinds of cause in public replies:

  • A possible terms-of-service violation. This is usually an automated flag, and it is sometimes wrong. Bulk dataset generation, traffic that looks like reselling access, and many free accounts from one person or network are common patterns behind it.
  • A technical flag, especially an exposed key. If Groq's systems see an API key in public, for example a GitHub commit, a public Hugging Face Space, or a front-end JavaScript bundle, the organization can be locked to protect it. Several public reports of this error come from apps running in public Hugging Face Spaces.
If the app runs on a public Hugging Face Space or the key ever sat in a repository, assume it leaked. Revoke it in the Groq console, move the key into a server-side secret, and say in your support email that you have done so.

How to get it lifted

  1. Revoke and replace every key in the organization, and remove keys from client code, notebooks and public Spaces. Put them in server-side environment variables or secrets.
  2. Check your traffic against Groq's terms, especially automated bulk jobs, several accounts and sharing your key with users.
  3. Email support@groq.com from the account owner's address. Include the organization id (org_… from the console), the exact error, the date it started, what your app does and roughly how much traffic it sends, and what you changed in steps 1 and 2. Short, factual emails are easiest for support to act on.
  4. Keep the app running while you wait. Groq has not published a response time. If users depend on the app, send the same OpenAI-format request to a second provider. Most Groq chat models are open-weight and served elsewhere under the same ids.
Python · same request, second OpenAI-compatible provider
import os
from openai import OpenAI

# Was: OpenAI(base_url="https://api.groq.com/openai/v1", api_key=os.environ["GROQ_API_KEY"])
client = OpenAI(
    base_url="https://api.inferenceapis.com/openai/v1",   # Groq-style path accepted
    api_key=os.environ["INFERENCE_API_KEY"],
)
resp = client.chat.completions.create(
    model="openai/gpt-oss-120b",          # same id as on Groq
    messages=[{"role": "user", "content": "ping"}],
    max_tokens=800,
)
print(resp.choices[0].message.content)

Only the base URL and the key change. If you use Groq for transcription, whisper-large-v3 and whisper-large-v3-turbo work the same way. See the speech-to-text API.

Frequently asked questions

Why is it a 400 and not a 401 or 403?

Groq returns it as invalid_request_error with status 400. Your key is still valid, so it is not an authentication failure. Check for code == "organization_restricted", not the status, so your app does not treat it like a malformed request and keep retrying.

How long does Groq take to unlock an organization?

Groq has not published one, and the error carries no ticket or reference number. That is why a second provider for production traffic is worth setting up before you need it, not during the outage.

I am on the free plan. Can I upgrade to get unblocked?

No. The restriction sits above the plan, and Groq's self-serve Developer tier upgrade has been paused for many accounts anyway. Only support can lift it.

Will moving to another provider get me around a terms violation?

It should not, and you should not try. Every serious provider has similar terms, including us. A second provider helps when the flag was a mistake, or a leaked key you have now rotated, and your users should not be down while support reviews it.

I see this through LiteLLM, LangChain or CrewAI. Is it the framework?

No. The framework passes Groq's body through (LiteLLM wraps it in OpenAILikeError). Look for organization_restricted in the message. Changing the model inside Groq will not help, but pointing the provider config at another OpenAI-compatible base URL will.

Where Inference APIs fits

Step 4 above keeps a legitimate app running while Groq reviews the account. Inference APIs serves openai/gpt-oss-120b, openai/gpt-oss-20b and Whisper under the same ids, at the Groq-style path /openai/v1, billed per request from a $5 top-up with no tier to unlock. Our own terms prohibit the same things Groq's do, so this is a second provider for working apps, not a way around a ban.

Something changed or wrong? Tell us and we will re-verify the entry.