Skip to content

Plugin OAuth auth methods silently ignored (shadowed by other plugins) #10063

@thoreinstein

Description

@thoreinstein

Description

Description

Plugin OAuth authentication methods are silently ignored when multiple plugins provide authentication for the same provider. Currently, the first matching plugin found "shadows" all others, preventing their authentication methods (like OAuth) from being displayed.

Root Cause

In packages/opencode/src/cli/cmd/auth.ts, the code uses Plugin.list().then(x => x.find(...)) to locate a plugin for a given provider. This returns only the first plugin found. If opencode-websearch-cited (which only supports API keys for Google) is loaded before opencode-gemini-auth (which supports OAuth for Google), the OAuth option is never presented to the user.

Plugins

opencode-gemini-auth,opencode-websearch-cited

OpenCode version

1.1.3

Steps to reproduce

  1. Install opencode-gemini-auth and opencode-websearch-cited.
  2. Run opencode auth login.
  3. Select "Google".
  4. Observe that only the API key prompt appears; the OAuth option is missing.

Screenshot and/or share link

No response

Operating System

macOS 26.2

Terminal

Ghostty

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions