Skip to main content
Configure OpenCode, the AI-powered terminal coding assistant, to use Eden AI for access to 500+ models.

Overview

OpenCode is a terminal-based AI coding assistant. By connecting it to Eden AI, you get:
  • 500+ models: Access OpenAI, Anthropic, Google, and more through a single API key
  • Auto-configured: A script fetches Eden AI’s full model catalog and writes your config automatically
  • Tool calling: All models in the generated config support function calling, which OpenCode requires

Setup

1. Install OpenCode

2. Generate your config

Download the script and run it:
This fetches all available Eden AI models and writes them directly to ~/.config/opencode/opencode.json.

3. Connect your API key

Launch OpenCode, run /connect, select Eden AI from the list, and paste your API key when prompted. Get your key from app.edenai.run → API Keys.

4. Start coding

Next Steps