Repository navigation
Description
Description
After connecting GitHub Copilot (OAuth device flow succeeds, credential stored and active), opencode models lists zero github-copilot/* models.
Direct API checks with the stored credential show the token is valid: GET https://api.githubcopilot.com/models returns ~49 models, each annotated with policy.state (enabled / disabled) and supported_endpoints. But OpenCode never surfaces a usable one:
- Dynamic sync yields nothing. With no explicit config, no
github-copilot/*model appears, even though the provider is registered (GET /api/providershowsgithub-copilotwithactivation: auto) and the account has entitled models. - Explicit
providers.github-copilot.modelsentries only survive if the ID exists in the bundled snapshot catalog. IDs such askimi-k3,gpt-5.4-mini,gpt-5.3-codex,claude-haiku-4.5,gpt-4o,gpt-4.1(all policy-enabled for the account, all present in the current models.devgithub-copilotcatalog) are silently dropped onopencode reload. Only snapshot-era IDs (e.g.gpt-5.4,claude-sonnet-5.5,gemini-3.8-flash,claude-opus-5) are kept. - The surviving snapshot IDs are all
policy.state=disabledfor the account, so using any of them fails:opencode run --model github-copilot/gemini-3.8-flashreturns400 model_not_supported. Snapshot IDs absent from the account's/models(e.g.kimi-k2.7-code) fail with400 model_not_available_for_integrator "opencode". modelIDoverrides break routing. An explicit entry with amodelIDdifferent from its key (e.g. keygpt-5.4withmodelID: kimi-k3) is dropped entirely:provider.no-route / Model unavailable: github-copilot/gpt-5.4.
Net effect: there is no way to select a usable Copilot model — the selectable set (stale snapshot, all policy-disabled) and the usable set (policy-enabled, missing from snapshot) do not intersect.
Plugins
None (no plugins configured; no MCP servers).
OpenCode version
2.0.22 (@opencode/cli, latest channel; verified newest published version)
Steps to reproduce
opencode auth login→ select GitHub Copilot → complete the device flow (succeeds, credential active).opencode models→ nogithub-copilot/*entries (onlyopencode/*free models).- Add explicit models under
providers.github-copilot.modelsin~/.config/opencode/opencode.json, thenopencode reload→ only snapshot-era IDs appear; current IDs (kimi-k3,gpt-5.4-mini,gpt-4o, …) are dropped. opencode run "hi" --model github-copilot/gemini-3.8-flash→400 {"code":"model_not_supported"}.
Screenshot and/or share link
N/A (CLI output; exact API error codes included above).
Operating System
Windows NT 10.0.26200 (win32 x64)
Terminal
PowerShell commands executed via local OpenCode server (TERM=xterm-256color)
Activity
github-actions commentedon Oct 3, 2026
This issue might be a duplicate of existing issues. Please check:
edwardEsmerson commentedon Oct 8, 2026
Additional reproduction and evidence from Linux/WSL2:
Environment
v2.0.25, latest channel6.6.87.2-microsoft-standard-WSL2)/home/solan/src/opencode-plugins/opencode-usageReproduction and observations
opencode auth listshows an active stored GitHub Copilot OAuth credential.opencode service status,/api/info).gpt-4.1andgpt-4o-mini.github-copilot/claude-haiku-5.5andgithub-copilot/gpt-5-minifail with:Account/API verification
Using the stored credential locally (token redacted):
GET https://api.githubcopilot.com/modelsreturns HTTP 200.GET https://api.github.com/copilot_internal/userreportschat_enabled: trueand an individualfree_educational_quotaaccount.COPILOT_OKforgpt-4.1andgpt-4o-mini.model_not_supportedfor the newer models OpenCode exposes.This indicates the OAuth credential, entitlement, and network are working. The failure appears to be stale/incorrect Copilot model discovery or filtering: OpenCode exposes models that are not callable for this account while omitting models that GitHub accepts.
A reconnect did not resolve it; restarting the OpenCode service only refreshed the stale inventory temporarily.
opencode-agent commentedon Oct 17, 2026
Closing as a duplicate of #34644.
GitHub Copilot Free and Student plans now only allow Auto model selection, so Copilot's
/modelsreturns every model withmodel_picker_enabled: falseand OpenCode ends up listing no Copilot models. #34644 tracks adding agithub-copilot/automodel for these plans; the fix is in progress in #55960.If explicitly configured
providers.github-copilot.modelsentries are still dropped after Auto ships, please open a focused issue for that part.