Gemini 3.1 Pro Preview

Gemini 3.1 Pro Preview by Google AI: $2 per 1M input and $12 per 1M output tokens, 1.0M context. Call it with one OpenAI-compatible API key, compare it with similar models, start free.

ReasoningReads imagesTool callingJSON schemaStreamingWeb searchPrompt cachingBatch

Gemini 3.1 Pro Preview is served by Google AI and called through odnoga on /v1/chat/completions, in the same OpenAI-compatible shape every other model on that endpoint uses. It is a reasoning model, so it spends extra output tokens working through a problem before answering — budget for higher output cost on hard tasks. It accepts images alongside text. It supports tool and function calling. It can be forced to return structured JSON. Its 1.0M-token context window sets how much input you can send in one request. Cached input is billed at $0.2 per 1M tokens, so repeated prefixes cost less.

Specification and price

VendorGoogle AI
Model IDgemini-3.1-pro-preview
Context window1.0M tokens
Max output66K tokens
Served on/v1/chat/completions
CapabilitiesReasoning, Reads images, Tool calling, JSON schema, Streaming, Web search, Prompt caching, Batch
Your plan
Per 1M tokensVendor costYour price on Free+7%
Input$2$2.15
Output$12$12.90
Cached input$0.2$0.215

Vendor cost is the list price per million tokens as recorded in the odnoga catalog; your price applies your plan margin with the same formula that bills every request — see pricing. Pricing

Call it through odnoga

const res = await fetch("https://api.odnoga.com/v1/chat/completions", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.ODNOGA_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    model: "gemini-3.1-pro-preview",
    messages: [{ role: "user", content: "Hello" }],
  }),
});

One endpoint, one key, one bill — /v1/chat/completions takes the same shape whichever vendor is behind it. Swap the model id and odnoga handles keys, routing, limits and cost accounting.

What Gemini 3.1 Pro Preview can do

Everything below is what the model itself supports. Ask for something it does not do and odnoga tells you before the request reaches the provider, instead of returning a worse answer.

Reasoning

Works through a problem step by step before answering, which costs more tokens and buys accuracy on hard tasks.

Reads images

Send a screenshot, a photo or a scan in the same message as your text.

Tool calling

The model can call functions you define and use what they return.

JSON mode

Answers with valid JSON instead of prose you would have to parse.

JSON schema

Answers in the exact shape you specify, so the response fits your types without a fallback path.

Streaming

Tokens arrive as they are produced, so your interface can answer immediately.

Web search

Can look something up rather than answer from training data alone. Billed per search.

Prompt caching

A prompt you send repeatedly is charged at the cached rate, which is a fraction of the input price.

Batch

Work that can wait goes through at a lower price.

Beyond text

Reads PDFs

Send a document and ask about it, without extracting the text yourself first.

Listens to audio

Takes recorded speech as input.

Watches video

Takes video as input and answers questions about what happens in it.

Finer control

  • Structured outputs · The provider guarantees the schema rather than merely aiming for it.

How to use Gemini 3.1 Pro Preview

Reviewed 2026-09-14

Best for

  • Complex problems across mixed sources: Google describes it as its most advanced reasoning Gemini model, handling text, audio, images, video, PDFs and whole code repositories.
  • Software engineering behaviour and agentic workflows that need precise tool use and reliable multi-step execution.
  • Analysis over very large inputs with a 1M-token context window.
  • Tasks where factual consistency and token efficiency matter more than raw speed.

Not the right pick when

  • High-volume, latency-sensitive traffic — a Flash tier is the intended answer.
  • Cost-sensitive batch work: Pro-tier pricing shows up quickly at scale.
  • Production paths that cannot tolerate a preview model id changing underneath them.

Practical tips through odnoga

  1. 01Use it for the hard tail of your traffic and a Flash tier for the rest — routing by prompt is the whole point of a gateway.
  2. 02Give it the sources rather than a summary of them; its advantage is comprehension across large, mixed inputs.
  3. 03Because it is a preview id, pin it in a managed prompt version and keep the previous model available for instant switch-back.
  4. 04Track cost per tenant: Pro-tier reasoning on long inputs is the most expensive combination in any catalog.

What a month costs

1,000 calls a month, 10,000 input tokens and 2,000 output tokens each, at your Free price (vendor cost +7%):

Input (10M tokens)$21.51
Output (2M tokens)$25.81
Your cost per month on Free$47.31

Vendor list cost $44.00 + odnoga margin $3.31 (+7%). Cached input or answer reuse lowers it; odnoga records both numbers per request.

If Gemini 3.1 Pro Preview is not the one

Models that take the same kind of input, are priced the same way, and do the closest thing to what this one does. Not a quality ranking — odnoga does not benchmark models.

ModelContextInput / 1MOutput / 1MCapabilities
Gemini 3.1 Pro Preview1.0M$2$12Reasoning, Reads images, Tool calling, JSON schema, Streaming, Web search, Prompt caching, Batch
Gemini 3.5 Flash1.0M$1.50$9Reasoning, Reads images, Tool calling, JSON schema, Streaming, Web search, Prompt caching, Batch
Claude Sonnet 51M$2$10Reasoning, Reads images, Tool calling, JSON schema, Streaming, Web search, Prompt caching, Batch
Claude Sonnet 5.51M$2$10Reasoning, Reads images, Tool calling, JSON schema, Streaming, Web search, Prompt caching, Batch

Questions

What is Gemini 3.1 Pro Preview built for?
Google describes it as refining the Gemini 3 Pro series with better thinking, improved token efficiency and a more grounded, factually consistent experience, optimised for software engineering and agentic workflows.
Should I run a preview model in production?
Only with a pinned prompt version and a tested fallback. odnoga lets you switch the production label back to the previous model without an application change.
Is the 1M context worth the cost?
Sometimes. Compare a long-context prompt against a retrieval-based one on the same frozen test cases — the laboratory reports tokens and cost next to pass rate, so the trade-off is measured rather than argued.

All models · Pricing · Docs · Compare models in the evaluation lab

Sources: Google AI for Developers — Gemini 3.1 Pro preview, Google DeepMind — Gemini 3.1 Pro model card

One gateway, every model.