Skip to content

Commit c5a4a82

Browse files
fix: dont show gpt-5.5-pro when using codex oauth (#33400)
Co-authored-by: Devin Oldenburg <devin@logicplanes.com>
1 parent 39d7394 commit c5a4a82

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

  • packages/opencode/src/plugin/openai

packages/opencode/src/plugin/openai/codex.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ const CODEX_API_ENDPOINT = "https://chatgpt.com/backend-api/codex/responses"
1313
const OAUTH_PORT = 1455
1414
const OAUTH_POLLING_SAFETY_MARGIN_MS = 3000
1515
const ALLOWED_MODELS = new Set(["gpt-5.5", "gpt-5.3-codex-spark", "gpt-5.4", "gpt-5.4-mini"])
16+
const DISALLOWED_MODELS = new Set(["gpt-5.5-pro"])
1617

1718
interface PkceCodes {
1819
verifier: string
@@ -370,6 +371,7 @@ export async function CodexAuthPlugin(input: PluginInput, options: CodexAuthPlug
370371
Object.entries(provider.models)
371372
.filter(([, model]) => {
372373
if (ALLOWED_MODELS.has(model.api.id)) return true
374+
if (DISALLOWED_MODELS.has(model.api.id)) return false
373375
const match = model.api.id.match(/^gpt-(\d+\.\d+)/)
374376
return match ? parseFloat(match[1]) > 5.4 : false
375377
})

0 commit comments

Comments
 (0)