Skip to content
Quotamainnet

API docs

An OpenAI- and Anthropic-compatible API for Claude, GPT, Gemini and Grok models, paid from the AI balance you get by burning credit tokens. Requests are served through OpenRouter.

Quickstart

  1. Hold launchpad coins to receive credit airdrops, then burn credits on the Credits page. 1 credit = $0.01 of balance in that family.
  2. Sign in with your wallet and create a key on the API keys page. Keys look like sk-aic-... and are shown once.
  3. Point any OpenAI-compatible client at https://quotapad.fun/v1.

Authentication

Send your key on every request, in either header:

  • Authorization: Bearer sk-aic-...
  • x-api-key: sk-aic-... (what Anthropic SDKs send)

Keys can have a total and a daily spend cap in USD. Requests over a cap are rejected before anything is charged.

Endpoints

Base URL: https://quotapad.fun/v1

  • POST /v1/chat/completions: OpenAI chat format, streaming supported (stream: true).
  • POST /v1/messages: Anthropic Messages format, streaming supported. Anthropic model names such as claude-sonnet-4-5-20250929 map to anthropic/claude-sonnet-4.5.
  • POST /v1/messages/count_tokens: token estimate for an Anthropic-format request.
  • GET /v1/models: every model with its credit family, context length and price per million tokens. No key needed.
  • GET /v1/balance: your spendable balance per family and this key's spend and caps.
  • GET /v1/usage?before=&limit=: this key's requests, newest first. Pass nextBefore from a response as before to page.

Powered by OpenRouter

We don't run the models ourselves. Every request is forwarded to OpenRouter, which routes it to the model's provider (Anthropic, OpenAI, Google or xAI) and reports back exactly what it cost.

  • The model list and prices come from OpenRouter's catalog and refresh every 10 minutes.
  • You pay OpenRouter's price for each request, plus the platform markup shown in the prices below.
  • Your prompts and responses pass through OpenRouter to the model provider under their policies. We keep only usage records (model, token counts, cost), not the content of your requests.
  • Model names and IDs are OpenRouter's, for example anthropic/claude-sonnet-4.5.

Models and credit families

Each model is paid from the balance of its family. Burning a credit token adds balance to that family only.

  • anthropic/* models are paid with qCLAUDE
  • openai/* models are paid with qGPT
  • google/* models are paid with qGEMINI
  • x-ai/* models are paid with qGROK

Billing

  • Before a request is forwarded, its worst-case cost (prompt plus the maximum output tokens) is reserved from your balance.
  • When it finishes, you are charged the exact cost OpenRouter reports for it (plus the platform markup) and the rest of the reservation is refunded.
  • If a stream is cut off (you disconnect, or the connection drops), you pay only for the tokens that were generated.
  • Per-key total and daily caps apply on top of your balance.
  • Without a max_tokens, a default output limit applies. Each request also has a cost ceiling.
  • Check your balance and this key's spend with GET /v1/balance.

Errors and rejected parameters

Errors use the OpenAI shape { "error": { "message", "type" } } on /v1/chat/completions and the Anthropic shape on /v1/messages.

  • 401: missing, invalid or revoked key.
  • 402: insufficient balance in the model's family, or a key cap reached. Burn more credits or raise the cap.
  • 400: invalid request. These parameters are rejected because they could run or bill a different model: models, route, provider, plugins, transforms, web_search_options, and n greater than 1.
  • 429: rate limited (120 requests per minute per key).
  • 502: the upstream provider failed. Nothing is charged.

Examples

curl

Chat completion
curl https://quotapad.fun/v1/chat/completions \
  -H "Authorization: Bearer sk-aic-..." \
  -H "Content-Type: application/json" \
  -d '{
    "model": "anthropic/claude-sonnet-4.5",
    "messages": [{"role": "user", "content": "Hello!"}]
  }'
Balance
curl https://quotapad.fun/v1/balance -H "Authorization: Bearer sk-aic-..."

OpenAI Python SDK

python
from openai import OpenAI

client = OpenAI(base_url="https://quotapad.fun/v1", api_key="sk-aic-...")

stream = client.chat.completions.create(
    model="anthropic/claude-sonnet-4.5",
    messages=[{"role": "user", "content": "Write a haiku about Solana."}],
    stream=True,
)
for chunk in stream:
    print(chunk.choices[0].delta.content or "", end="")

OpenAI JavaScript SDK

javascript
import OpenAI from "openai";

const client = new OpenAI({ baseURL: "https://quotapad.fun/v1", apiKey: process.env.AIC_API_KEY });

const res = await client.chat.completions.create({
  model: "openai/gpt-5",
  messages: [{ role: "user", content: "Explain bonding curves in one paragraph." }],
});
console.log(res.choices[0].message.content);

Anthropic Python SDK

python
import anthropic

# base_url is the API root, without /v1: the SDK adds /v1/messages itself
client = anthropic.Anthropic(base_url="https://quotapad.fun", api_key="sk-aic-...")

msg = client.messages.create(
    model="claude-sonnet-4-5-20250929",
    max_tokens=1024,
    messages=[{"role": "user", "content": "Hello, Claude"}],
)
print(msg.content[0].text)

Claude Code

Run Claude Code against your qCLAUDE balance:

shell
ANTHROPIC_BASE_URL=https://quotapad.fun ANTHROPIC_AUTH_TOKEN=sk-aic-... claude

Models and prices

Live from GET /v1/models: OpenRouter's catalog and prices, in USD per million tokens.

Loading models…