Route requests to
GPT-5.6 Terra
with Merge Gateway

Apply your own routing policies, reduce token costs automatically, and see every routing decision in real time with Merge Gateway.

What GPT-5.6 Terra costs to run

| Vendor | Input / 1M tokens | Output / 1M tokens | Zero data retention | | --- | ---: | ---: | --- | | OpenAI | $1.875 | $11.25 | Yes |

Test GPT-5.6 Terra
with Gateway’s Simulator

See a prompt's output, token spend, latency, and more with GPT-5.6 Terra.

Route requests to GPT-5.6 Terra in minutes

To get started in seconds, add our Gateway Implementation skill to your project, or pick your preferred SDK below. Check out our other quick start skills here.
Install the Merge Gateway SDK
Python
Copied!
1$ pip install merge-gateway-sdk
Send a request
Python
Copied!
1from merge_gateway import MergeGateway
2
3client = MergeGateway(api_key="YOUR_API_KEY")
4
5response = client.responses.create(
6    model="openai/gpt-5.2",
7    input=[
8        {"type": "message", "role": "system", "content": "You are a helpful programming tutor. Explain the concepts clearly with practical examples."},
9        {"type": "message", "role": "user", "content": "Explain the concept of recursion in programming with a simple set of examples."},
10    ],
11)
12
13print(response.output[0].content[0].text)
Try a diffrent model
Swap the model string to route to a different provider. No other code changes needed.
Anthropic
Copied!
1response = client.responses.create(
2    model="anthropic/claude-sonnet-4-20250514",
3    input=[
4        {"type": "message", "role": "system", "content": "You are a helpful programming tutor. Explain the concepts clearly with practical examples."},
5        {"type": "message", "role": "user", "content": "Explain the concept of recursion in programming with a simple set of examples."},
6    ],
7)
Point to Gateway
Python
Copied!
1from openai import OpenAI
2
3client = OpenAI(
4    api_key="YOUR_API_KEY",
5    base_url="https://api-gateway.merge.dev/v1/openai",
6)
Send a request
Use the standard chat.completions.create method. No provider prefix needed on the model name.
Python
Copied!
1response = client.chat.completions.create(
2    model="gpt-5.2",
3    messages=[
4        {"role": "system", "content": "You are a helpful programming tutor. Explain the concepts clearly with practical examples."},
5        {"role": "user", "content": "Explain the concept of recursion in programming with a simple set of examples."},
6    ],
7)
8
9print(response.choices[0].message.content)
Install packages
Copied!
1npm install merge-gateway-ai-sdk-provider ai
Create the provider
TypeScript
Copied!
1import { createMergeGateway } from "merge-gateway-ai-sdk-provider";
2
3const gateway = createMergeGateway({
4  apiKey: "YOUR_API_KEY",
5});
Send a request
Use generateText to send a request. Model names use the provider/model format.
TypeScript
Copied!
1import { generateText } from "ai";
2
3const { text } = await generateText({
4  model: gateway("openai/gpt-4o"),
5  prompt: "Explain the concept of recursion in programming with a simple set of examples.",
6});
7
8console.log(text);
If you already have @ai-sdk/openai installed, point it at Gateway with a base URL change:
TypeScript
Copied!
1import { createOpenAI } from "@ai-sdk/openai";
2
3const gateway = createOpenAI({
4  apiKey: "YOUR_API_KEY",
5  baseURL: "https://api-gateway.merge.dev/v1/ai-sdk",
6});
7
8// All generateText/streamText calls work unchanged
Install the Merge Gateway SDK
Anthropic SDK
Copied!
1from anthropic import Anthropic
2
3client = Anthropic(
4    api_key="YOUR_API_KEY",
5    base_url="https://api-gateway.merge.dev/v1/anthropic",
6)
7
8message = client.messages.create(
9    model="claude-sonnet-4-20250514",
10    max_tokens=1024,
11    messages=[
12        {"role": "user", "content": "Explain the concept of recursion in programming with a simple set of examples."},
13    ],
14)
15
16print(message.content[0].text)

Explore other models available in Merge Gateway

model logo
Amazon Nova 2 Lite
model logo
Amazon Nova 2 Lite
model logo
Amazon Nova 2 Sonic
model logo
Amazon Nova Lite
model logo
Amazon Nova Micro
model logo
Amazon Nova Premier
model logo
Amazon Nova Pro
model logo
Amazon Nova Pro
model logo
Claude 3.7 Sonnet
model logo
Claude 3.7 Sonnet
model logo
Claude 4 Opus 20250514
model logo
Claude Fable 5
model logo
Claude Fable 5
model logo
Claude Haiku 4.5 (20251001)
model logo
Claude Opus 4.1 (20250805)
model logo
Claude Opus 4 (20250514)
model logo
Claude Opus 4.5 (20251101)
model logo
Claude Opus 4.6
model logo
Claude Opus 4.6
model logo
Claude Opus 4.7
model logo
Claude Opus 4.7
model logo
Claude Opus 4.8
model logo
Claude Opus 4.8
model logo
Claude Opus 5

GPT-5.6 Terra FAQ

Got more questions about GPT-5.6 Terra? We've covered several below, and as always, this reflects what was known as of July, 2026, so some details may change as OpenAI updates the model.

Heading

What other models does OpenAI offer?

OpenAI's current lineup spans three GPT-5.6 tiers plus a set of earlier-generation and reasoning-specialized models still in production use. Here are some other models OpenAI supports:

  • GPT-5.6 Sol: This is the flagship tier of the GPT-5.6 family, built for the hardest reasoning, coding, and agentic workloads where output quality matters more than cost. It carries the same roughly 1 million token context window as Terra but costs twice as much per token, at $5.00 input and $30.00 output per million tokens
  • GPT-5.6 Luna: The fastest and cheapest tier in the family, aimed at high-volume, latency-sensitive work like routing, tagging, and short-form generation. Pricing runs at $1.00 input and $6.00 output per million tokens, well under half of Terra's rate
  • GPT-5.5: The previous-generation flagship, still common in production for teams that haven't migrated. It matches the roughly 1 million token context window of the GPT-5.6 family but generally scores lower on Artificial Analysis's Intelligence Index than the newer tiers
  • GPT-5.4 mini: A smaller, older-generation model priced at $0.75 input and $4.50 output per million tokens, aimed at cost-sensitive classification and short-form tasks. It predates the Sol, Terra, and Luna naming and sits below the GPT-5.6 family on both price and capability
  • o4-mini: A reasoning-specialized model built around extended step-by-step thinking rather than general-purpose scale, aimed at math, logic, and multi-step technical problems. It's priced and evaluated separately from the GPT-5.6 lineup since it optimizes for depth of reasoning per query over raw throughput

How does GPT-5.6 Terra differ from OpenAI's other models?

Terra is the balanced, mid-tier model in the GPT-5.6 family, positioned between flagship Sol and economy-tier Luna on both price and capability.

  • Pricing: Terra costs $2.50 per million input tokens and $15.00 per million output tokens, exactly half of Sol's $5.00/$30.00 and more than double Luna's $1.00/$6.00, placing it deliberately in the middle of the family's price ladder
  • Context window: Terra, Sol, and Luna all share a roughly 1.05 million token context window, with up to 922,000 tokens usable as input and 128,000 reserved for output, so context capacity isn't what separates the three tiers
  • Benchmark performance: Terra scores 55 on the Artificial Analysis Intelligence Index, an aggregate built from evaluations including GPQA Diamond, SciCode, and GDPval-AA v2. That places it behind Sol's top configurations, which reach as high as 59, but at roughly half the cost per token
  • Generational comparison: Terra's Intelligence Index score sits at or above GPT-5.5's typical range, meaning the mid-tier model in the newer family already matches the prior generation's flagship on measured intelligence
  • Speed: Terra generates output at approximately 144 tokens per second. Sol trades some of that speed for additional accuracy on harder problems, while Luna trades accuracy for higher throughput

Terra fits teams that want most of Sol's reasoning quality for everyday coding, structured data extraction, and agentic workflows without paying flagship prices. Reserve Sol for tasks where accuracy is worth the premium, and Luna for high-volume calls where speed and cost matter more than reasoning depth.

What models should I consider using alongside GPT-5.6 Terra?

No single model is optimal for every task. Here are models worth pairing with GPT-5.6 Terra depending on what your product needs:

  • Claude Opus 4.6 (Anthropic): Route your most demanding reasoning tasks here, especially ones requiring nuanced judgment, long-horizon planning, or careful multi-step analysis, when Terra's mid-tier reasoning isn't enough and the added cost is worth it
  • Gemini 3.5 Flash (Google): Use for high-volume, low-cost inference like classification, tagging, or simple extraction, where Terra's reasoning depth is unnecessary overhead and per-request cost matters more than accuracy headroom
  • Mistral Medium 3.5 (Mistral): A solid fit for structured data extraction and multilingual tasks at a lower cost than Terra, useful when a workflow needs consistent, schema-shaped output rather than open-ended reasoning
  • Grok 4.3 (xAI): Consider this for tasks that benefit from more current or real-time context, giving you a second data source and reasoning style to cross-check Terra's output on time-sensitive queries

What are the challenges of using GPT-5.6 Terra in my product?

Like any production LLM, GPT-5.6 Terra comes with tradeoffs worth planning for:

  • Provider dependency: Running entirely on OpenAI means an API outage, rate limit, or deprecation notice on Terra directly disrupts your product, since there's no automatic fallback to another provider without added infrastructure
  • Cost at scale: Output tokens are billed at 6x the input rate ($15.00 versus $2.50 per million), so verbose responses or multi-step agentic chains compound quickly if usage isn't actively monitored and capped
  • Reasoning latency: As a reasoning-capable model, Terra takes longer to return a first token than non-reasoning models of similar size, which makes it a weaker fit for real-time chat interfaces or interactions with tight response budgets
  • Configuration complexity: Terra ships in multiple reasoning-effort configurations, so teams need to evaluate and tune the right effort level for their latency, cost, and quality tradeoffs before relying on it in production
  • Migration friction: Teams moving from GPT-5.5, GPT-4o, or earlier models need to re-validate prompts and tool-calling behavior, since formatting and response conventions can shift across model generations

Why should I use Merge Gateway to route LLM requests with GPT-5.6 Terra and every other model?

Using GPT-5.6 Terra through Merge Gateway gives you access to the model itself and the infrastructure layer around it:

  • One API, every provider: Reach GPT-5.6 Terra and every other major LLM through a single endpoint and API key. Swap providers by changing the model string alone, with no application code changes required
  • Intelligent routing and automatic failover: Merge routes around OpenAI outages automatically. Routing policies based on cost, latency, or quality can cut spend by 40-60% without touching your application code, which matters given the cost gap between Terra and its Sol and Luna siblings
  • Cost governance: Set hard or soft project budgets so Terra spend stays within plan, particularly useful given its output-heavy pricing. Every request is attributed to a model, project, and tag in one billing dashboard across all providers
  • Build Your Own Router: Define what "best" means for your traffic by selecting from curated ML benchmarks or adding your own eval scores. The router scores each available model against your weights and picks a winner per request, with a plain-language explanation of every decision
  • Security and compliance controls: Apply DLP rules and prompt injection protection before every request reaches OpenAI. Enforce per-project model and region policies without building that logic into your application

How can I start routing requests to GPT-5.6 Terra via Merge Gateway?

Getting GPT-5.6 Terra running through Merge Gateway takes a few minutes:

1. Create an account and get your API key from the dashboard.

2. Install the Merge Gateway SDK: run pip install merge-gateway-sdk (Python) or npm install merge-gateway-sdk (Node). Alternatively, if you're already using the OpenAI SDK, set base_url = "https://api-gateway.merge.dev/v1/openai" and your existing code works as-is.

3. Make your first request using the provider/model format. For GPT-5.6 Terra, the model string is openai/gpt-5.6-terra. Swap the model string to route to any other provider without changing anything else.

4. Configure a routing policy in the dashboard to set failover behavior, cost limits, and optimization strategy. A practical starting point: name Terra as primary with Luna as a lower-cost fallback for when budgets are near their limit.

Full setup instructions and SDK references are in the Merge Gateway docs.

Try GPT-5.6 Terra through Merge Gateway

Route, observe, and control AI requests across providers from one API.