Skip to content

API key entered via /model dialog not loaded until restart #8073

@darshkpatel

Description

@darshkpatel

Description

When entering an API key manually through the /model dialog for providers like Anthropic, the API key is not immediately usable. Users must restart OpenCode for the key to be loaded.

Plugins

No response

OpenCode version

1.1.14

Steps to reproduce

  • open /models menu
  • select provider anthropic
  • select manually enter api key
  • enter an api key
  • select an anthropic model
  • send a prompt
  • you'll notice opencode complains about missing api key

Screenshot and/or share link

opencode-apikey-bug.mp4

Operating System

No response

Terminal

No response

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