What is OpenCode?
OpenCode.ai is an open-source, AI-powered code assistant that helps you understand, generate, and refactor code across many languages and frameworks. It can answer questions about your codebase, suggest improvements, and automate repetitive coding tasks directly in your workflow. Being open source is beneficial because it’s transparent, can be self-hosted, and allows the community to audit, extend, and improve the tool, leading to faster innovation and greater trust.
This Article refers to the offical OpenCode Documentation
Prequisites
- You have installed Open Code on your Client
- You have setup an valid API Key to access the Claude GenAI Cloud Models like Sonnet etc.
Add an MCP server to OpenCode
Make Sure OpenCode is installed and working properly
Create a new File called opencode.json within your Work Directory
{
"$schema": "https://opencode.ai/config.json",
// Theme configuration
"theme": "opencode",
"model": "anthropic/claude-sonnet-4-5",
"autoupdate": true,
"mcp": {
"simplifier-mcp": {
"type": "local",
"command": ["npx", "-y", "@simplifierag/simplifier-mcp@latest"],
"enabled": true,
"environment": {
"SIMPLIFIER_BASE_URL": "https://<yoursimplifierurl>",
"SIMPLIFIER_TOKEN": "You will find the Token within your User Profile -> Security"
},
},
}
}
Add Simplifier Token (you can find by logging into Simplifier and go to User Profile -> Security) and your Simplifier Base URL.
Best Practice is when you open a Terminal in your local IDE like Visual Studio Code and start the OpenCode Client with
opencode
Then you can edit files and using the opencode for working with AI.












