GenAIWiki
beginner

Call Gemini 3.8 Flash in the Gemini API

Start with Gemini 3.8 Flash: model code gemini-3.8-flash, 1M context, thinking levels, intro pricing, and when to use Live or Antigravity instead.
geminigemini-3-8-flashgoogleagentscodingapi

10 min read

FeaturedUpdated todayVerified recentlyInformation score 92

Key insights

Concrete technical or product signals.

  • Pin gemini-3.8-flash. Live and Cyber are different SKUs.
  • thinking_level supports low/medium/high. minimal errors.
  • Intro $0.75/$3.75 per 1M tokens ends 31 Dec 2026.

Use cases

Where this shines in production.

  • First generate-content call on Gemini 3.8 Flash
  • Choosing Flash vs Live vs Antigravity
  • Budgeting the January 2027 list-price step-up

Limitations & trade-offs

What to watch for.

  • Not a computer-use implementation dump. Computer use is Preview on the card.
  • SDK method names move; confirm the Gemini API docs on the day you ship.
  • This is not Gemini 3.5 Pro (unreleased) and not Flash Cyber.

Gemini 3.8 Flash is Google's September 2, 2026 Flash workhorse for software engineering, agents, and long-context multimodal work. The stable model code is gemini-3.8-flash.

This is not a Live API voice model. Flash takes text, images, video, audio, and PDF, and returns text. For spoken sessions use Start a Gemini 3.8 Live Voice Session.

1. Confirm Flash is the right SKU

JobModel / product
Coding, agents, documents, generate-contentgemini-3.8-flash
Spoken full-duplex sessiongemini-3.8-live
TranscriptsGemini 3.5 Transcribe
IDE / CLI coding agent on GeminiGoogle Antigravity
Fairwind-gated defensive cyberGemini 3.8 Flash Cyber (not public API)

3.7 Flash remains supported for efficiency-first workloads. 3.8 can spend more tokens at higher thinking effort.

2. Get a key and pin the model ID

  1. Create a Gemini API key in Google AI Studio.
  2. Install the current GenAI SDK (pip install -U google-genai or npm install @google/genai).
  3. Send gemini-3.8-flash. Do not send a Live model ID on generate-content. Do not invent a gemini-3.8-pro ID.
from google import genai

client = genai.Client()
response = client.models.generate_content(
    model="gemini-3.8-flash",
    contents="Summarize this pull request in five bullets.",
)
print(response.text)

Keep the key on a server or in a secret store. Confirm the request shape against the Gemini API docs the day you implement — the SDK surface moves.

3. Set thinking on purpose

The Gemini 3.8 Flash model card supports thinking at low, medium, and high. minimal is not supported and returns an error.

Use low for short instruction-following. Use high for long-horizon coding or multi-step agents. Pin the level in evals so cost and latency stay comparable.

Official card capabilities that matter on day one: function calling, code execution, file search, structured outputs, search grounding, URL context, caching, computer use (Preview). Live API is not supported on this SKU.

4. Price the intro window

Google kept the same introductory price as 3.7 Flash: $0.75 input / $3.75 output per million tokens through 31 December 2026. List price becomes $1.50 / $7.50 on 1 January 2027. Budget the step-up before you hard-code Flash as the default.

Context is 1,048,576 input tokens and 65,536 output tokens on the model card. Batch, Flex, and Priority inference are listed as supported.

5. What not to do

  • Do not use Flash as a speech-to-speech model. There is no audio output on the card.
  • Do not treat Antigravity as the API. The IDE/CLI agent and gemini-3.8-flash are related but not the same integration.
  • Do not call Flash Cyber from a self-serve key. That SKU is Fairwind-gated.

Official sources

Continue learning

Related models, implementation guides, comparisons, and concepts.