Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions packages/models/src/models/openai.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1115,6 +1115,10 @@ export const openaiModels = [
{
providerId: "openai",
externalId: "gpt-5-chat-latest",
// Shut down by OpenAI on 2026-07-23 (announced 2026-04-22);
// requests now 404 with "has been deprecated". Replacement is
// gpt-5.6-sol.
deactivatedAt: new Date("2026-07-23"),
inputPrice: "1.25e-6",
outputPrice: "10.0e-6",
cachedInputPrice: "0.125e-6",
Expand Down Expand Up @@ -1248,6 +1252,11 @@ export const openaiModels = [
{
providerId: "openai",
externalId: "gpt-5.1-codex",
// Shut down by OpenAI on 2026-07-23 (announced 2026-04-22);
// requests now 404 with "has been deprecated". Replacement is
// gpt-5.6-sol. The azure mapping below stays active — Azure runs
// its own schedule and does not retire this until 2027-05-15.
deactivatedAt: new Date("2026-07-23"),
Comment on lines +1255 to +1259

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🩺 Stability & Availability | 🟠 Major | ⚡ Quick win

Add the Azure retirement dates to provider metadata.

The comments state that the Azure mappings retire on May 15, 2027 and July 13, 2027. The Azure provider objects do not set deactivatedAt. The runtime availability checks therefore continue to treat these mappings as active after those dates.

Add future deactivatedAt values to the Azure mappings.

Proposed fix
+deactivatedAt: new Date("2027-05-15"), // gpt-5.1-codex
+deactivatedAt: new Date("2027-05-15"), // gpt-5.1-codex-mini
+deactivatedAt: new Date("2027-07-13"), // gpt-5.2-codex

Also applies to: 1308-1312, 2351-2355

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/models/src/models/openai.ts` around lines 1255 - 1259, Add future
deactivatedAt dates to the Azure provider objects associated with the mappings
at the referenced locations, using the retirement dates stated in their
comments: May 15, 2027 and July 13, 2027. Keep the existing Azure mappings and
comments unchanged, and ensure each Azure object’s metadata is used by the
runtime availability checks.

serviceTiers: ["priority"],
serviceTierMultipliers: { priority: 2 },
inputPrice: "1.25e-6",
Expand Down Expand Up @@ -1296,6 +1305,11 @@ export const openaiModels = [
{
providerId: "openai",
externalId: "gpt-5.1-codex-mini",
// Shut down by OpenAI on 2026-07-23 (announced 2026-04-22);
// requests now 404 with "has been deprecated". Replacement is
// gpt-5.6-terra. The azure mapping below stays active — Azure runs
// its own schedule and does not retire this until 2027-05-15.
deactivatedAt: new Date("2026-07-23"),
inputPrice: "0.25e-6",
outputPrice: "2e-6",
cachedInputPrice: "0.025e-6",
Expand Down Expand Up @@ -2334,6 +2348,11 @@ export const openaiModels = [
{
providerId: "openai",
externalId: "gpt-5.2-codex",
// Shut down by OpenAI on 2026-07-23 (announced 2026-04-22);
// requests now 404 with "has been deprecated". Replacement is
// gpt-5.6-sol. The azure mapping below stays active — Azure runs
// its own schedule and does not retire this until 2027-07-13.
deactivatedAt: new Date("2026-07-23"),
inputPrice: "1.75e-6",
outputPrice: "14.0e-6",
cachedInputPrice: "0.175e-6",
Expand Down
Loading