Quotaflow
llms.txtOpenAPIDashboard
Model Library

Google Gemini text API quickstart

Model IDs and access

Use an exact ID returned by your key. The public catalog does not guarantee live capacity or every optional capability.

Unprefixed compatibility IDs remain accepted; prefer the namespaced IDs returned by discovery.

export QUOTAFLOW_API_KEY="YOUR_QUOTAFLOW_API_KEY"
curl https://api.quotaflow.ai/openai/v1/models \
  -H "Authorization: Bearer $QUOTAFLOW_API_KEY"

First request

OpenAI SDK base URL: https://api.quotaflow.ai/openai/v1. Keep your key on your server.

curl https://api.quotaflow.ai/openai/v1/chat/completions \
  -H "Authorization: Bearer $QUOTAFLOW_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "google/gemini-3.8-flash",
  "messages": [
    {
      "role": "user",
      "content": "Design an order-management API and explain its main endpoints."
    }
  ],
  "max_tokens": 4096,
  "stream": false
}'

Read choices[0].message.content. For a plain-text conversation, send earlier user and assistant messages in messages; tool conversations also need the tool calls and matching results.

Responses clients

curl https://api.quotaflow.ai/openai/v1/responses \
  -H "Authorization: Bearer $QUOTAFLOW_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "google/gemini-3.8-flash",
  "input": "Design an order-management API and explain its main endpoints.",
  "max_output_tokens": 4096,
  "store": false,
  "stream": false
}'

Responses is stateless: send the full conversation in input every time. Do not use previous_response_id, conversation, prompt, background, or store: true. Keep returned reasoning and tool-call items intact when replaying them, and include matching tool results.

Gemini-native clients

Use base URL https://api.quotaflow.ai and the native field names. Native token counting and cached-content APIs are separate from OpenAI generation endpoints.

curl "https://api.quotaflow.ai/v1beta/models/gemini-3.8-flash:generateContent" \
  -H "x-goog-api-key: $QUOTAFLOW_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "contents": [
    {
      "role": "user",
      "parts": [
        {
          "text": "Design an order-management API and explain its main endpoints."
        }
      ]
    }
  ],
  "generationConfig": {
    "maxOutputTokens": 4096
  }
}'

Read candidates[].content.parts[].text. Preserve model-returned thought signatures unchanged for multi-turn requests. Text, tools and media availability is model-, surface- and request-specific; do not infer it from another Gemini model. Image models use the image guide, not this text request.

Compatibility and output budgets

On OpenAI-style clients, do not send Gemini-native top-level thinking or native generationConfig. Use the corresponding endpoint-specific fields, or switch to the Gemini-native request format. Some catalog identities have unknown availability; verify the actual key rather than treating this list as a live health report.

Use the output cap for the endpoint you call; these fields are not interchangeable. If an answer ends at its output limit, inspect its status/stop reason before increasing the budget within the model limit. For streaming, consume the endpoint-specific events until completion; do not assume a first chunk is the final answer.

401 indicates an authentication problem; check key access on 403. Correct invalid request fields on 400 instead of retrying unchanged. Use bounded backoff for temporary 429/503 capacity failures. Check model access with the same key and base URL; no guide guarantees live supply or a universal price.

See Responses API, Chat Completions and billing.