OpenCode
OpenCode is an open-source coding agent for the terminal, desktop and IDEs. Add Flow AI as an OpenAI-compatible provider and pick its models with /models.
Add Flow AI as a provider
Add this to ~/.config/opencode/opencode.json:
opencode.json
Add every Flow AI model you want under models, keyed by its id from the Models page.
To keep the key out of the config file, leave out apiKey, run /connect inside OpenCode, choose Flow AI and paste your key. OpenCode stores it in ~/.local/share/opencode/auth.json.
Troubleshooting
- Authentication errors: check
HYPERFLOW_API_KEYis set in the shell that starts OpenCode, or run/connectagain. - Model not found: the key under
modelsmust match the model id exactly, such asopenai/gpt-6-luna. - The agent doesn’t edit files: pick a model with tool calling.