Developers

Change one line.
Keep your code.

The endpoint is OpenAI-compatible: point your existing SDK at api.gc4.ai and your gift-card balance pays for every model.

Email-only account · No credit card · Ever
api.gc4.ai
-base_url="https://api.openai.com/v1"+base_url="https://api.gc4.ai/v1"
That's the whole migration. 42 models, one balance,per-token prices mirrored from openrouter.ai.
Quickstart

Send your first request.

The snippets below carry a placeholder key. Grab a real one. It's email-only, no card. Then paste it in and run.

Get a key
gc4-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
quickstart.gc4.ai
1from openai import OpenAI
2
3client = OpenAI(
4 base_url="https://api.gc4.ai/v1",
5 api_key="gc4-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", # replace with your key
6)
7
8r = client.chat.completions.create(
9 model="anthropic/claude-haiku-4.5",
10 messages=[{"role": "user", "content": "Say hi in 5 words."}],
11)
12print(r.choices[0].message.content)
Copy the Python snippet
Expected response
{
  "id": "chatcmpl-example",
  "object": "chat.completion",
  "created": 1786752000,
  "model": "anthropic/claude-haiku-4.5",
  "choices": [
    {
      "index": 0,
      "message": {
        "role": "assistant",
        "content": "Hi there, five words exactly."
      },
      "finish_reason": "stop"
    }
  ],
  "usage": {
    "prompt_tokens": 13,
    "completion_tokens": 8,
    "total_tokens": 21,
    "cost": 0.000053
  }
}
Example: 21 tokens · $0.000053 · successful usage is ledgered to your account
Parameters

Sampling controls.

The API honors max_tokens, temperature, and top_p. Models that support tools also honor tools and tool_choice. response_format is accepted and ignored; it is not supported.

For reasoning-capable models, an explicit max_tokens value below 1024 is raised to 1024 on both endpoints. If a non-streaming chat completion uses that output budget for internal reasoning and returns no visible content, the response includes a warning with retry guidance.

Account

Read your balance and key spend.

GET /v1/me returns integer micro-USD balances and this key's settled usage this month. In-flight reservations are excluded, so the settled figure may be lower than the amount used for spend-cap enforcement.

account.gc4.ai
$ curl https://api.gc4.ai/v1/me \
    -H "Authorization: Bearer gc4-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
Errors

Every error you'll meet.

An empty balance is a hard stop: there is no overdraft and no negative balance, ever. 60 requests per minute per key sustained, with short bursts up to 120 allowed. Retry-After is an integer number of seconds with a minimum of 1. Upstream provider errors use the documented OpenAI-compatible error shapes.

A non-streaming response arrives as a single JSON body when generation completes. If the connection drops or the body does not parse as JSON, treat it as a failed attempt and retry. Each request is billed only for the tokens it actually used.

401Bad or revoked key
{ "error": { "message": "Invalid authentication credentials.", "type": "authentication_error", "code": 401 } }
404Model id not on the ledger (typo'd slug)
{ "error": { "message": "The model `meta/llama-4-scou` does not exist. Did you mean `meta/llama-4-scout`?", "type": "invalid_request_error", "code": 404, "metadata": { "suggestion": "meta/llama-4-scout" } } }
402Balance empty: hard stop, never overdraft
{ "error": { "message": "Insufficient credits to fulfill this request. Add credits to continue.", "type": "insufficient_quota", "code": 402, "metadata": { "balance": "$0.0123", "balance_micro": 12345, "top_up_url": "https://gc4.ai/convert" } } }
429Rate limited: 60 req/min per key, bursts to 120
{ "error": { "message": "Rate limit exceeded. Please slow down and retry.", "type": "rate_limit_exceeded", "code": 429, "metadata": { "retry_after": 1 } } }