Models
ChatGooglefasttoolsmultimodal1m-context

Gemini 3.8 Flash

Google Gemini 3.8 Flash: fast, low-cost multimodal model with a 1M-token context.

Model ID: gemini-3.8-flash

Playground

Price · Vercel AI Gateway
1M input tokens$0.675
1M output tokens$3.375

Credits for max_tokens are held first, then settled to the actual usage.

Start a conversation. Replies stream in and are billed by actual token usage.

Pricing by provider

Prices are per unit; requests without a provider are routed to the cheapest provider that supports your parameters.

ProviderOptionPrice (USD)Credits
Vercel AI GatewayAll options$0.7510% off$0.675 / 1M input tokens169 / 1M input tokens
All options$3.7510% off$3.375 / 1M output tokens844 / 1M output tokens
OpenRouterAll options$0.82510% off$0.743 / 1M input tokens186 / 1M input tokens
All options$4.12510% off$3.712 / 1M output tokens929 / 1M output tokens

API reference

Endpoints

Base URL: https://01router.com/api/v1

POST/chat/completionsChat completion (OpenAI-compatible, stream or not)

Authentication

Send your API key as a Bearer token. Requests are billed to the key owner's credits.

Authorization: Bearer sk_xxxxxxxxxxxxxxxx
Get an API key

Request body

NameTypeRequiredDescription
modelstringYes"gemini-3.8-flash"
providerstringNoPin a provider; omit to auto-route to the cheapest. One of: vercel | openrouter
messagesarrayYesOpenAI-format messages, each with role and content.
streambooleanNotrue returns an SSE stream.
max_tokensintegerNoOutput token cap; credits are pre-held for it (default 4096).

Example request

curl https://01router.com/api/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gemini-3.8-flash",
    "provider": "vercel",
    "messages": [{ "role": "user", "content": "Hello!" }],
    "stream": false
  }'

Response

Chat models (GPT, Claude, Gemini, Grok, DeepSeek…) use the OpenAI Chat Completions format, so the official OpenAI SDKs work with base URL https://01router.com/api/v1. Set "stream": true for server-sent events. Credits for the prompt plus max_tokens (4,096 when unset) are held first, then settled to the real token usage once the reply ends; the same request id appears in the X-Gateway-Request-Id header and the task log.

{
  "id": "chatcmpl-…",
  "object": "chat.completion",
  "model": "gemini-3.8-flash",
  "choices": [
    {
      "index": 0,
      "message": {
        "role": "assistant",
        "content": "Hello! How can I help?"
      },
      "finish_reason": "stop"
    }
  ],
  "usage": {
    "prompt_tokens": 9,
    "completion_tokens": 8,
    "total_tokens": 17
  }
}

Auth, routing, billing and error codes are covered in Gateway API reference