Blog

Gemini API "User Location Is Not Supported": What It Means and How to Fix It

Short answer

The Gemini API returns User location is not supported for the API use when a request comes from a place that is not on Google's list of available regions. The check is on where the request comes from, not on your key or your code. You can call the same Gemini models through TeamoRouter instead: one API key, the base URL https://api.teamorouter.com, and both the OpenAI-compatible and the Gemini-native format, so official SDKs and Gemini CLI only need a different base URL. The newest model is gemini-4-argon; the everyday one is gemini-3.8-flash.

What the error means

Google publishes a list of countries and territories where the Gemini API and Google AI Studio are available. A request from anywhere else is rejected with a 400 error:

text
User location is not supported for the API use.

Two situations produce it:

  • You are in a region that is not on the list.
  • Your code runs on a server whose address Google places outside the list. Developers on Google's own forum report the error from cloud and VPS hosts in listed countries, while the same key works from another network.

In both cases, changing the key or the SDK version does not help.

Getting an API key that works

  1. Open the TeamoRouter console and sign up with email or a Google account.
  2. Create an API key. It looks like sk-teamo-... and works for every model: Gemini, Claude and GPT.
  3. Top up a balance by card or USDT.

Your requests go to api.teamorouter.com, so the location check applies to our servers, not to yours.

Which Gemini models are available

Per 1 million tokens, in USD:

Model Model ID List price, input / output TeamoRouter, input / output Context
Gemini 4 Argon gemini-4-argon $2 / $10 ≈ $0.58 / $2.90 1M
Gemini 3.8 Flash gemini-3.8-flash $0.75 / $3.75 ≈ $0.22 / $1.09 1M
Gemini 3.5 Flash-Lite gemini-3.5-flash-lite $0.30 / $2.50 ≈ $0.09 / $0.73 1M

Figures are as of the publish date; live prices and the full model list are on the pricing page. For the flagship, see Gemini 4 Argon API.

How to choose: Argon for complex multi-step work and large codebases, 3.8 Flash as the everyday model, Flash-Lite for bulk jobs where the unit price matters.

Connecting

OpenAI-compatible format — use this if your code or tool already speaks the OpenAI API:

bash
curl https://api.teamorouter.com/v1/chat/completions \
  -H "Authorization: Bearer YOUR_KEY" \
  -H "content-type: application/json" \
  -d '{
    "model": "gemini-3.8-flash",
    "messages": [{"role": "user", "content": "Explain a token in one sentence"}]
  }'
python
from openai import OpenAI

client = OpenAI(base_url="https://api.teamorouter.com/v1", api_key="YOUR_KEY")
resp = client.chat.completions.create(
    model="gemini-3.8-flash",
    messages=[{"role": "user", "content": "Outline an article about request caching"}],
)
print(resp.choices[0].message.content)

Gemini-native format — use this with Google's official SDKs:

bash
curl https://api.teamorouter.com/v1beta/models/gemini-3.8-flash:generateContent \
  -H "Authorization: Bearer YOUR_KEY" \
  -H "content-type: application/json" \
  -d '{
    "contents": [
      {"role": "user", "parts": [{"text": "Explain a token in one sentence"}]}
    ]
  }'

For streaming, use streamGenerateContent?alt=sse. Full reference: API integration.

Gemini CLI

Gemini CLI is Google's terminal coding agent. Three environment variables point it at TeamoRouter:

bash
npm install -g @google/gemini-cli

mkdir -p ~/.gemini && cat > ~/.gemini/.env <<'ENV'
GOOGLE_GEMINI_BASE_URL=https://api.teamorouter.com
GEMINI_API_KEY=YOUR_KEY
GEMINI_API_KEY_AUTH_MECHANISM=bearer
ENV

On first run of gemini, choose "Use Gemini API Key". Step-by-step: Gemini CLI with TeamoRouter.

Paying for usage

You top up a balance in the console and are charged only for tokens actually used — no subscription.

  • Card — Visa, Mastercard and other major cards via Stripe.
  • USDT — "Pay with crypto" in the top-up dialog.

FAQ

Does a new API key fix "User location is not supported"? No. The check is on the address the request comes from, so a new key from the same place gets the same answer.

Can I keep using Google's official SDKs? Yes. Set the base URL to https://api.teamorouter.com and use a TeamoRouter key, through the GOOGLE_GEMINI_BASE_URL and GEMINI_API_KEY environment variables or the SDK's custom endpoint option.

How is a TeamoRouter key different from a Google AI Studio key? An AI Studio key works for Gemini only and only from available regions. A TeamoRouter key covers Gemini, Claude and GPT.

Is there a free tier? Billing is pay-as-you-go. There are free models in other families; the list is on the pricing page.

Are there request limits? Yes, per model — see the rate limits page.

Next steps

Ready to connect?Log in · top up · create an API key — three steps to start.