Skip to content

AI Integration · Engineering

GPT-5 API Shutdown on Dec 11: Migrate to GPT-6.2 Sol

OpenAI shuts down gpt-5, gpt-5-mini, gpt-5-nano and o3 in the API on December 11, 2026. Here's what replaces each, what breaks in your requests, and the cost.

Prathviraj Singh

Prathviraj Singh

13 min read

A figure with a ladder standing under the one glowing street lamp on a dusk road lined with dark, unlit lamps

Sponsored

Share

The GPT-5 API shutdown is nine days away. On December 11, 2026, OpenAI turns off gpt-5, gpt-5-mini, gpt-5-nano, gpt-5-pro, o3 and o3-pro in the API, and any request that still names one of them stops working. The fix for most apps is gpt-6.2-sol, but a find-and-replace on the model string won’t carry you all the way. Tool calls, a few request parameters and your caching setup all need a look, and one of the listed replacements costs four times what you pay now.

Everything below comes from OpenAI’s own docs as they read on December 2: the deprecations page, the latest-model guide, the pricing page and the three model pages.

GPT-5 API shutdown: what goes away and what replaces it

Six models and their dated snapshots shut down on December 11, 2026. OpenAI lists gpt-6.2-sol as the replacement for gpt-5 and o3, gpt-6.1-terra for gpt-5-mini, and gpt-6-luna for gpt-5-nano. The two pro models map to gpt-6.2-sol with reasoning.mode set to pro, in the Responses API only.

Shutting down December 11Listed replacement
gpt-5, gpt-5-2025-08-07gpt-6.2-sol
gpt-5-mini, gpt-5-mini-2025-08-07gpt-6.1-terra
gpt-5-nano, gpt-5-nano-2025-08-07gpt-6-luna
gpt-5-pro, gpt-5-pro-2025-10-06gpt-6.2-sol with reasoning.mode: pro (Responses API)
o3, o3-2025-04-16gpt-6.2-sol
o3-pro, o3-pro-2025-06-10gpt-6.2-sol with reasoning.mode: pro (Responses API)

The page defines shutdown in one line: “The model no longer accepts requests through the standard API.” It doesn’t say which error you get. Don’t count on a retry or fallback path you wrote for rate limits to catch it. Treat it as a hard failure for every call site that still names an old model.

Pinning a dated snapshot doesn’t help either. gpt-5-2025-08-07 is on the list next to the alias.

The notice went out on June 11. Six months is easy to spend when everything keeps working.

Find every call site first

The model name hides in more places than the code that calls the SDK. Start with a grep, and keep the pattern tight enough that it doesn’t flag gpt-5.4, gpt-5.6-sol or o3-mini, which aren’t part of this shutdown:

grep -rnE --exclude-dir={node_modules,.git,dist,.venv} \
  "(^|[^a-zA-Z0-9.-])(gpt-5(-mini|-nano|-pro)?|o3(-pro)?)(-2025-[0-9]{2}-[0-9]{2})?([^a-zA-Z0-9.-]|$)" .

Then check the places grep can’t see:

  • Environment variables and secrets managers (OPENAI_MODEL=gpt-5 set in a hosting dashboard last year).
  • Gateway and router config. If you route through LiteLLM or OpenRouter, the alias your app sends may map to gpt-5 in a YAML file in another repo. The LLM routing guide covers where those mappings live.
  • Database rows. Apps that let an admin or a customer pick a model store the string per tenant.
  • Scheduled and batch jobs, which only fail on the night they next run.
  • Eval suites and CI. A grader pinned to o3 breaks your pipeline, not your product, but it still breaks.

The usage page in the OpenAI dashboard groups spend by model. If gpt-5 or o3 shows any traffic in the last week and your grep found nothing, something outside the repo is calling it.

What breaks when you change the model string

Tool calling moves to the Responses API

This is the change that takes real work. The latest-model guide says: “GPT-6.2 Astra and GPT-6.2 Sol support Chat Completions, but tool calling requires Responses.” The GPT-6.1 Terra page carries the same sentence, “Tool calling requires the Responses API.” (The GPT-6 Luna page is a little looser and allows Chat Completions function calling with reasoning_effort set to none. Read the page for the model you land on.)

So a gpt-5 integration that sends tools to /v1/chat/completions can’t switch models in place. Plain text and structured output calls can stay on Chat Completions. Anything with function calling has to be ported.

Here is the same single-tool loop on the Responses API with gpt-6.2-sol:

import json
from openai import OpenAI

client = OpenAI()


def get_order_status(order_id: str) -> dict:
    return {"order_id": order_id, "status": "shipped", "eta_days": 2}


tools = [{
    "type": "function",
    "name": "get_order_status",
    "description": "Look up the shipping status of an order.",
    "strict": True,
    "parameters": {
        "type": "object",
        "properties": {"order_id": {"type": "string"}},
        "required": ["order_id"],
        "additionalProperties": False,
    },
}]

input_items = [
    {"role": "developer", "content": "You are a support agent for an online store."},
    {"role": "user", "content": "Where is order A1042?"},
]

response = client.responses.create(
    model="gpt-6.2-sol",
    reasoning={"effort": "low"},
    tools=tools,
    input=input_items,
)

# Keep the model's output items (reasoning and function calls) in order.
input_items += response.output

for item in response.output:
    if item.type == "function_call" and item.name == "get_order_status":
        args = json.loads(item.arguments)
        input_items.append({
            "type": "function_call_output",
            "call_id": item.call_id,
            "output": json.dumps(get_order_status(args["order_id"])),
        })

final = client.responses.create(model="gpt-6.2-sol", tools=tools, input=input_items)
print(final.output_text)

Three things differ from the Chat Completions version you’re replacing:

Chat CompletionsResponses
Tool schema nested under functionname, description and parameters at the top level of the tool
Calls arrive in message.tool_calls[], keyed by idCalls are function_call items in response.output, keyed by call_id
Results go back as role: "tool" messagesResults go back as function_call_output items

Set strict yourself instead of relying on a default. The function calling guide notes that “Chat Completions requests remain non-strict by default,” so a port can change how tightly arguments follow your schema. Strict mode needs additionalProperties: false and every property listed in required. If your schemas have optional fields, the structured outputs guide shows how to express them.

Parameters to remove or rename

The guide’s parameter list is short, and each item is the kind of thing a wrapper adds without anyone remembering.

  • Sampling controls are gone. For Chat Completions, omit temperature, top_p, logprobs and top_logprobs. For Responses, omit temperature, top_p and top_logprobs, and drop message.output_text.logprobs from include.
  • gpt-5 accepted reasoning effort minimal, low, medium and high. For GPT-6.2 the guide says: “If you currently use none or minimal, use low instead.” The Sol model page adds that the API rejects none.
  • gpt-5-pro and o3-pro have no pro model to move to. Pro is now a mode: reasoning={"mode": "pro"} on gpt-6.2-sol, through Responses. The reasoning guide says mode and effort are independent settings, and that pro mode bills at the model’s standard token rates while using more tokens.

That minimal to low step has a side effect. More reasoning means more reasoning tokens, and those count against max_output_tokens. A request capped at a few hundred output tokens can now come back with status: "incomplete" and no visible text, after you’ve paid for the input and the reasoning. OpenAI’s reasoning guide recommends “reserving at least 25,000 tokens for reasoning and outputs” while you’re finding the real number. If you set tight caps to control spend on gpt-5 with minimal effort, raise them before the switch and watch for incomplete afterwards.

A helper that rewrites requests

If your app builds Responses requests in one place, a small function can carry the mechanical changes while you port the tool-calling paths by hand:

REPLACEMENTS = {
    "gpt-5": "gpt-6.2-sol",
    "gpt-5-2025-08-07": "gpt-6.2-sol",
    "gpt-5-mini": "gpt-6.1-terra",
    "gpt-5-mini-2025-08-07": "gpt-6.1-terra",
    "gpt-5-nano": "gpt-6-luna",
    "gpt-5-nano-2025-08-07": "gpt-6-luna",
    "gpt-5-pro": "gpt-6.2-sol",
    "gpt-5-pro-2025-10-06": "gpt-6.2-sol",
    "o3": "gpt-6.2-sol",
    "o3-2025-04-16": "gpt-6.2-sol",
    "o3-pro": "gpt-6.2-sol",
    "o3-pro-2025-06-10": "gpt-6.2-sol",
}
PRO_MODELS = {"gpt-5-pro", "gpt-5-pro-2025-10-06", "o3-pro", "o3-pro-2025-06-10"}
DROPPED = ("temperature", "top_p", "top_logprobs")


def migrate_responses_request(req: dict) -> dict:
    """Rewrite a Responses API request for a model that shuts down on Dec 11."""
    old_model = req["model"]
    if old_model not in REPLACEMENTS:
        return req

    new = {k: v for k, v in req.items() if k not in DROPPED}
    new["model"] = REPLACEMENTS[old_model]

    reasoning = dict(new.get("reasoning") or {})
    if reasoning.get("effort") == "minimal":
        reasoning["effort"] = "low"
    if old_model in PRO_MODELS:
        reasoning["mode"] = "pro"
    if reasoning:
        new["reasoning"] = reasoning

    if new.pop("prompt_cache_retention", None) is not None:
        new["prompt_cache_options"] = {"ttl": "30m"}

    # GPT-6.2 appends top-level instructions after input, which breaks the
    # cached prefix. Put them in a developer message at the front instead.
    instructions = new.get("instructions")
    if instructions and new["model"].startswith("gpt-6.2"):
        del new["instructions"]
        items = new["input"]
        if isinstance(items, str):
            items = [{"role": "user", "content": items}]
        new["input"] = [{"role": "developer", "content": instructions}, *items]

    return new

Ship it behind a flag, log every request it rewrites, and delete it once the old names are out of your config. A shim like this left in place for a year becomes the thing nobody dares touch.

Prompt caching works differently, and it changes your bill

The last block of that helper deals with the least obvious change in the whole migration. On gpt-5, the top-level instructions string sat at the front of the prompt, which is where you want stable text for caching. The latest-model guide says “Models starting with GPT-6.2 append top-level instructions after input in the Responses API.” The prompt caching guide spells out the cost: OpenAI bills those instruction tokens at the uncached input rate on every request.

Picture a support bot with a 4,000-token system prompt in instructions. On gpt-5 that prefix was cached after the first call. Move the same request to gpt-6.2-sol unchanged and those 4,000 tokens are billed at full price every time, at a higher input rate than before. The fix is the one in the helper: put stable instructions in a developer message at the start of input.

Three more caching changes from the same guide:

  1. Cache writes cost money now. For GPT-5.6 and later, a write is billed at 1.25 times the uncached input rate for the default 30-minute lifetime (2.5 times for a 12-hour lifetime). gpt-5 had no cache-write charge.
  2. Reads got cheaper. Cached input on gpt-6.2-sol is $0.10 per million tokens, which is 0.05 times the input rate. On gpt-5 it was $0.125, or 0.1 times.
  3. prompt_cache_retention is replaced by prompt_cache_options.ttl, with "30m" and "12h" as the values. Anything else returns a 400 invalid_request_error.

Who comes out ahead? Agents and chat apps that resend a long, stable prefix many times inside half an hour. Who loses? Low-traffic endpoints where each prefix is written once and never read again, because you now pay the 1.25 times write rate and get nothing back. The LLM response caching guide covers the application-level cache that sits in front of all this.

What the switch costs

Grouped bar chart of input and output prices per million tokens for gpt-5, gpt-5-mini, gpt-5-nano and o3 against their listed replacements: gpt-5 input rises from $1.25 to $2.00 on gpt-6.2-sol, gpt-5-mini rises from $0.25 to $1.00 input and $2.00 to $5.00 output on gpt-6.1-terra, gpt-5-nano rises from $0.05 to $0.10 input on gpt-6-luna, and o3 output rises from $8.00 to $10.00

Standard rates per million tokens, from the pricing page:

Retiring modelInput / outputListed replacementInput / output
gpt-5$1.25 / $10.00gpt-6.2-sol$2.00 / $10.00
gpt-5-mini$0.25 / $2.00gpt-6.1-terra$1.00 / $5.00
gpt-5-nano$0.05 / $0.40gpt-6-luna$0.10 / $0.50
o3$2.00 / $8.00gpt-6.2-sol$2.00 / $10.00

The gpt-5 row is mild: input up 60%, output flat. The gpt-5-mini row is the one to stop on. Take a workload of 100,000 requests a day at 3,000 input and 500 output tokens each, no caching. That’s 300 million input tokens and 50 million output tokens a day.

ModelDaily cost for that workload
gpt-5-mini (today)$75 + $100 = $175
gpt-6.1-terra (listed replacement)$300 + $250 = $550
gpt-6-luna$30 + $25 = $55

Same token counts across all three, which is a simplification, since each model spends a different number of reasoning tokens to reach an answer. The direction holds anyway. Accepting the listed replacement roughly triples this bill, and dropping to Luna cuts it by two thirds. Which one is right depends on whether Luna passes your evals. For classification, extraction and routing, try Luna first. Keep Terra for the calls where Luna’s answers fail your checks. The guide to reducing LLM API costs goes through that kind of model tiering in more detail.

One more line on the pricing page matters for long prompts. Above 272,000 input tokens, the GPT-6 models double their input and cache rates and charge 1.5 times for output, for the whole request. gpt-5 capped input at 272,000 tokens, so nothing you run today crosses that line. The new 1,050,000-token context window makes it tempting to stuff more in. Know that the price steps up when you do.

There’s a longer treatment of per-task cost versus per-token price in the GPT-6.1 Sol cost-per-task breakdown, and it applies here: count the tokens a model burns on your tasks before you trust a per-million number.

A cutover plan for the next nine days

  1. Today: run the grep, check env vars, gateway config and stored per-tenant model names. Write down every call site and whether it uses tools.
  2. Port the tool-calling paths to Responses. That’s the only part with real code changes, so start it first.
  3. Replay a saved set of real requests through old and new models side by side and compare outputs, token counts and cost. If you don’t have that set yet, the LLM eval guide explains how to build one from production logs. Do it while gpt-5 still answers, because after December 11 you lose the baseline.
  4. Put the model name behind config if it isn’t already, and send a small share of traffic to the new model. Watch for incomplete responses, 400s from leftover parameters, and the cached_tokens figure in usage. If you don’t log per-request token usage yet, the LLM observability guide covers the tooling.
  5. Check rate limits per model in your dashboard. Limits are set per model and tier, and the Sol model page lists 5,000 requests and 1,000,000 tokens a minute for its lowest tier. A batch job that fit under your gpt-5 limits may not fit under these.
  6. Move everything by December 9 or 10. Leave a day or two of margin. Don’t plan a cutover for the 11th.

Prompts need a pass too, though a lighter one. The guide suggests revisiting lines like “be concise” in system prompts, because the GPT-6.2 models are already more direct by default and the instruction can push answers too short.

The next deadlines are already on the calendar

December 11 is one date in a run of them on the same deprecations page:

Shutdown dateModelsListed replacement
January 6, 2027tts-1, tts-1-hd, gpt-4o-mini-ttsgpt-realtime-2.1-mini
January 14, 2027GPT-4o, GPT-4o mini, GPT-4.1, GPT-4.1 mini snapshotsgpt-6-luna
January 20, 2027gpt-realtime, gpt-audio and the 4o audio modelsgpt-realtime-2.1, gpt-audio-1.5
February 26, 2027whisper-1 and the 4o transcribe modelsgpt-live-transcribe or gpt-transcribe
April 1, 2027gpt-5.1, gpt-5.4-nano, gpt-5.3-codexgpt-6.2-sol, gpt-6-luna

The January 14 date deserves a look now. If any of your code still calls gpt-4o or gpt-4.1, the listed replacement for all four is Luna, the smallest model in the family. That swap needs its own round of evals.

So do the audit once, for every date in that table, and widen the grep to match. Then put the model name behind one config value, keep the replayable request set from step 3, and add the deprecations page to whatever your team reads monthly. After that, the next shutdown notice is a config change and an eval run. This one, with nine days left, is a port.

Frequently asked questions

When does the GPT-5 API shut down?
December 11, 2026. OpenAI announced the deprecation on June 11, 2026, and its deprecations page lists that shutdown date for gpt-5, gpt-5-mini, gpt-5-nano, gpt-5-pro, o3 and o3-pro, along with their dated snapshots such as gpt-5-2025-08-07. After shutdown a model no longer accepts requests through the standard API.
What replaces gpt-5-mini in the OpenAI API?
OpenAI lists gpt-6.1-terra as the replacement, at $1.00 per million input tokens and $5.00 per million output tokens. gpt-5-mini was $0.25 and $2.00. If the workload is classification, extraction or routing, test gpt-6-luna at $0.10 and $0.50 first, because it is cheaper than the model you are leaving.
Do I have to move from Chat Completions to the Responses API?
Only if you use tools. GPT-6.2 Sol, GPT-6.1 Terra and GPT-6 Luna all support the Chat Completions endpoint for plain text and structured output. OpenAI's migration guide says tool calling on GPT-6.2 Sol requires Responses, so any function-calling code path has to be ported.

Sources

Sponsored

Sponsored

Discussion

Join the conversation.

Comments are powered by GitHub Discussions. Sign in with your GitHub account to leave a comment.

Sponsored