Skip to content

Instantly share code, notes, and snippets.

@ben-vargas
Last active October 13, 2025 02:38
Show Gist options
  • Save ben-vargas/dc19470ef98b5e67f7cbb4104f39ee0b to your computer and use it in GitHub Desktop.
Save ben-vargas/dc19470ef98b5e67f7cbb4104f39ee0b to your computer and use it in GitHub Desktop.
Config for opencode plugin: opencode-openai-codex-auth

Config for opencode plugin: opencode-openai-codex-auth

For those who might be having edge case behavior, or oddity with start/restart of opencode not retaining last used model properly, or "changing to a different model name" it's likely because of incorrect recommended setup in the opencode.json config file documented in the plugin repo.

You might try the config below, where model id is the key in the models object rather than user-friendly name.

This solved the odd behavior for me with launching opencode and /models slash command - it also provides shorter model names and easier search for all models with "oauth".

image
{
"$schema": "https://opencode.ai/config.json",
"provider": {
"openai": {
"options": {
"reasoningEffort": "medium",
"reasoningSummary": "auto",
"textVerbosity": "medium",
"include": [
"reasoning.encrypted_content"
]
},
"models": {
"gpt-5-codex-low-oauth": {
"name": "GPT-5 Codex Low (OAuth)",
"options": {
"reasoningEffort": "low",
"reasoningSummary": "auto",
"textVerbosity": "medium"
},
},
"gpt-5-codex-medium-oauth": {
"name": "GPT-5 Codex Medium (OAuth)",
"options": {
"reasoningEffort": "medium",
"reasoningSummary": "auto",
"textVerbosity": "medium"
},
},
"gpt-5-codex-high-oauth": {
"name": "GPT-5 Codex High (OAuth)",
"options": {
"reasoningEffort": "high",
"reasoningSummary": "detailed",
"textVerbosity": "medium"
},
},
"gpt-5-minimal-oauth": {
"name": "GPT-5 Minimal (OAuth)",
"options": {
"reasoningEffort": "minimal",
"reasoningSummary": "auto",
"textVerbosity": "low"
},
},
"gpt-5-low-oauth": {
"name": "GPT-5 Low (OAuth)",
"options": {
"reasoningEffort": "low",
"reasoningSummary": "auto",
"textVerbosity": "low"
},
},
"gpt-5-medium-oauth": {
"name": "GPT-5 Medium (OAuth)",
"options": {
"reasoningEffort": "medium",
"reasoningSummary": "auto",
"textVerbosity": "medium"
},
},
"gpt-5-high-oauth": {
"name": "GPT-5 High (OAuth)",
"options": {
"reasoningEffort": "high",
"reasoningSummary": "detailed",
"textVerbosity": "high"
},
}
}
}
},
"plugin": [
"[email protected]"
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment