OpenCode setup guide
Add MoLoop as an OpenCode custom provider and choose a current model from the catalog.
Overview
OpenCode reads providers from a JSON configuration file. Add MoLoop as an OpenAI-compatible provider, then choose the active coding model from the MoLoop catalog.
Quick configuration
Prepare this base URL and API key. Anonymous examples show a safe placeholder.
Configure OpenCode with CC Switch
Import the current MoLoop OpenAI-compatible endpoint and API key into the OpenCode configuration in CC Switch.
Endpoint: https://api.moloop.io/v1
Base URL: https://api.moloop.io/v1
API key: YOUR_API_KEYCompatibility
Chat Completions
Streaming
Tool calling
Step-by-step setup
Open the OpenCode configuration file
Press Ctrl + O in OpenCode and open the user configuration. On Windows, replace YOUR_USER with the current username.
Windows: C:/Users/YOUR_USER/.config/opencode/opencode.json
macOS/Linux: ~/.config/opencode/opencode.jsonAdd the provider configuration
Merge the MoLoop provider into the provider object. If the file is used only for OpenCode, you can use the complete configuration below.
{
"$schema": "https://opencode.ai/config.json",
"provider": {
"moloop": {
"name": "MoLoop",
"npm": "@ai-sdk/openai-compatible",
"discoverModels": true,
"options": {
"apiKey": "YOUR_API_KEY",
"baseURL": "https://api.moloop.io/v1"
}
}
}
}Save and reload
Save with Ctrl + S, then run Developer: Reload Window. OpenCode registers the provider after the reload.
Choose a model
Open the model picker and switch to MoLoop. discoverModels loads the current catalog from /v1/models.
Recommended models
Coding agents usually need reliable tool calling and enough context. Copy the exact model ID from the catalog.
Things to know
With discoverModels enabled, OpenCode reads /v1/models at startup, so you do not need to maintain a model list.
If the provider is missing, check JSON quotes, braces, and trailing commas before reloading the window.
The model ID must exactly match the MoLoop catalog; do not add another provider prefix.
On older OpenCode versions without discovery, add a models object under the provider and list the exact IDs you need.
Готовы начать?
Получите API-ключ и начните использовать MoLoop в этих инструментах.