OpenCode
Connect OpenCode to Sovereign using a custom OpenAI-compatible provider.
Official docs:
Recommended Surface
Use the OpenAI-compatible surface:
Setup
- Run
/connect. - Choose
Other. - Enter a provider ID such as
sovereign. - Paste your API key.
- Add the provider to
opencode.json.
Example opencode.json
Notes
- OpenCode's docs recommend
@ai-sdk/openai-compatiblefor providers that expose/v1/chat/completions. - If you build a custom flow around
/v1/responses, OpenCode also documents switching to@ai-sdk/openai.