SunsetDiff

OpenRouter: where a model slug lives

OpenRouter's quickstart puts the slug in the model field of a chat completions request. The example ~openai/gpt-sol-latest is a latest alias. A pinned call uses a specific slug instead. When that slug is an OpenAI id in the shutdown table, swap it for the official replacement.

Last reviewed . Publisher: SunsetDiff.

Steps

  1. Read the model field. The chat completions body, the OpenAI SDK model argument, and the OpenRouter SDK model field are the same slug.
  2. Decide alias or pin. A value that starts with ~ is a latest alias in the quickstart. A shutdown swap uses the specific replacement slug.
  3. Edit fallbacks. The models array is tried in order after the first model errors. Update that list when an entry shuts down.
  4. Read the tool pages. The quickstart posts to the chat completions endpoint. It does not document a Responses switch.
  5. Check the id. Check the id with lookup JSON, the MCP check_model tool, or a status badge before you ship the new string.

Where the model id lives

The quickstart sends POST /api/v1/chat/completions with a model field. Its example is ~openai/gpt-sol-latest. The page says that value is a latest alias that always resolves to the newest model in the OpenAI GPT Sol family, and that you can substitute any model slug.

The same page shows the slug on the OpenAI SDK pointed at https://openrouter.ai/api/v1, on the OpenRouter Python and TypeScript SDKs, and on the Agent SDK callModel model field. This page does not include an API key.

Slug from the OpenRouter quickstart

model = "~openai/gpt-sol-latest"

Source: OpenRouter quickstart , checked October 25, 2026.

How to pin or swap it

To pin, replace the ~ alias with a specific slug from the OpenRouter catalog. To swap a provider id that is shutting down, use the official replacement from the table as that slug. OpenRouter slugs are prefixed with the provider, so an OpenAI id gpt-4o is not always the same string as the OpenRouter slug.

The model fallbacks guide says the models array is tried in order when the first model returns an error. The swap guide quotes that page, including the extra_body.models shape used with the OpenAI SDK. The ids in that sample are the guide's examples.

Arguments quoted on the swap guide from the fallbacks page

model = "~openai/gpt-sol-latest"
extra_body = {
    "models": ["~anthropic/claude-sonnet-latest", "gryphe/mythomax-l2-13b"]
}

Sources: OpenRouter quickstart , OpenRouter model fallbacks , checked October 25, 2026.

GPT-6 function tools

The quickstart posts to /api/v1/chat/completions. It does not document a Responses API switch, so this page does not invent one.

If the slug you send is an OpenAI model, OpenAI's Using GPT-6 guide still applies to that provider: GPT-6 Astra and GPT-6.1 Sol tool calling requires the Responses API, and GPT-6 Sol and GPT-6 Luna accept function tools on Chat Completions only with reasoning effort none. Read the error pages before you send tools.

Sources: OpenRouter quickstart , Using GPT-6 , checked October 25, 2026.

Upcoming shutdowns in this dataset

gpt-4.1-2025-04-14, gpt-4.1-mini-2025-04-14, gpt-4o-2024-08-06, gpt-4o-2024-11-20, and gpt-4o-mini-2024-07-18 shut down on 2027-01-14. The official replacement on these rows is gpt-6-luna.

gpt-4.1, gpt-4.1-mini, gpt-4o, and gpt-4o-mini have no shutdown date on their own records. A request that sends the short id is not the dated snapshot row. Open the model page before you treat the short id as shut down.

Rows are upcoming OpenAI chat models in the gpt-4o, gpt-4.1, gpt-4-turbo, gpt-4, and gpt-3.5-turbo families. Audio, realtime, transcribe, and search ids are not in this table. The same id on another platform is in the other-platforms column. The full calendar is upcoming shutdowns. Provider wording for the shutdown day is on what happens on shutdown day.

5 upcoming OpenAI chat shutdowns from this dataset.
Shutdown Provider Model Replacement Other platforms
2027-01-14
source, checked 2026-10-26
OpenAI GPT-4.1 (gpt-4.1-2025-04-14)
gpt-4.1-2025-04-14
gpt-6-luna
Switch guide: gpt-6-luna
Azure OpenAI: shuts down on 2027-10-14
2027-01-14
source, checked 2026-10-26
OpenAI GPT-4.1 mini (gpt-4.1-mini-2025-04-14)
gpt-4.1-mini-2025-04-14
gpt-6-luna
Switch guide: gpt-6-luna
Azure OpenAI: shuts down on 2027-10-14
2027-01-14
source, checked 2026-10-26
OpenAI GPT-4o (gpt-4o-2024-08-06)
gpt-4o-2024-08-06
gpt-6-luna
Switch guide: gpt-6-luna
Azure OpenAI: shuts down on 2027-10-01
2027-01-14
source, checked 2026-10-26
OpenAI GPT-4o (gpt-4o-2024-11-20)
gpt-4o-2024-11-20
gpt-6-luna
Switch guide: gpt-6-luna
Azure OpenAI: shuts down on 2027-04-14
2027-01-14
source, checked 2026-10-26
OpenAI GPT-4o mini (gpt-4o-mini-2024-07-18)
gpt-4o-mini-2024-07-18
gpt-6-luna
Switch guide: gpt-6-luna
Azure OpenAI: shuts down on 2027-10-01

Detect a dying model

These checks read SunsetDiff. They do not call the model provider.

Related SunsetDiff pages

Other frameworks

All frameworks

Questions

What does the ~ prefix mean on OpenRouter?

The quickstart says ~openai/gpt-sol-latest is a latest alias for the newest model in the OpenAI GPT Sol family. A pinned request uses a specific slug instead.

Where do the dates in the shutdown table come from?

From SunsetDiff model records for upcoming OpenAI chat ids in the gpt-4o, gpt-4.1, gpt-4-turbo, gpt-4, and gpt-3.5-turbo families. The sentence above the table is built from those records when the site is built. Each row links the provider source stored on that record.

How do I check one model id from this page?

Open lookup JSON and replace gpt-4o with your id. Or call check_model on the MCP server. Or use a status badge. No API key.