Skip to main content

CloudBase AI Toolkit + OpenCode

🚀 OpenCode + CloudBase = Full-stack application from idea to launch in minutes.

GitHub Stars Open Source License

💡 Why choose OpenCode + CloudBase AI Toolkit? OpenCode is an open-source AI programming CLI tool, supporting multiple AI models and the MCP protocol, with powerful code generation and project management capabilities. Combined with the CloudBase AI Toolkit, it allows you to describe requirements in natural language, and AI automatically generates and deploys full-stack applications to the Tencent Cloud development platform. It is especially suitable for command-line developers, automated deployment scenarios, and multi-environment management.

✨ Core Advantages

🎯 Development EfficiencyDeployment Speed🛡️ Stability and Reliability
AI automatically generates code and architecture
Built-in best practice rules for cloud development
Intelligent error fixing and optimization
One-click deployment to Tencent Cloud development
Domestic CDN accelerated access
Serverless architecture with no Ops required
Platform verified by 3.3 million developers
Enterprise-grade security and stability
Comprehensive monitoring and logging system

🚀 5-Minute Quick Start

Select pre-configured project templates, ready to use out-of-the-box:

Method 2: Integrate with existing projects

If you already have a project, you can integrate in just 3 steps:

# 1. Configure MCP (See detailed steps below for specific configuration)
# 2. Download AI Rules
# 3. Start Using

After configuration is complete, run OpenCode and say: "Log in to CloudBase" to begin!

🔧 Detailed Configuration Guide

Step 1: Install OpenCode

Download and install the OpenCode CLI tool from OpenCode GitHub.

# Install with npm
npm install -g opencode

# Or install with yarn
yarn global add opencode

# Or download the binary files directly from GitHub

Step 2: Configure CloudBase MCP

[!TIP] If the number of tools remains 0 after installation, please refer to the FAQ

Create a .opencode.json file in the project root directory:

{
"mcpServers": {
"cloudbase": {
"command": "npx",
"args": [
"npm-global-exec@latest",
"@cloudbase/cloudbase-mcp@latest"
],
"env": {
"INTEGRATION_IDE": "OpenCode"
}
}
}
}

Step 3: Enable AI Rules

OpenCode supports multiple rule file formats and already includes the OPENCODE.md rule file. For existing projects, tell the AI:

Download CloudBase AI rules in the current project

If you only want to download configuration files related to OpenCode to avoid cluttering your project files, you can specify the IDE type:

Download CloudBase AI rules in the current project, containing only the OpenCode configuration

Step 4: Start Development

Use the OpenCode CLI to converse with the AI:

# Start OpenCode
opencode

# Or ask directly
opencode "Log in to CloudBase"

🎯 Get Started

After configuration is complete, tell the AI:

Log in to CloudBase

Then you can start development, for example:

Create an online voting system that supports creating polls, participating in voting, and result statistics, using cloud database for storage, and finally deploy it.

🌟 CloudBase AI Toolkit Open-Source Project

🔥 Join the Open-Source Community

GitHub CNB Community

⭐ Star the Project | 🤝 Contribute Code | 💬 Technical Discussion

🛠️ Troubleshooting

Frequently Asked Questions

Q: MCP connection failed? A:

  1. Check if the configuration file format is correct
  2. Restart OpenCode
  3. Confirm that the network connection is working properly
  4. Check the Node.js version (recommended 18+)

Q: Does the AI-generated code not meet expectations? A:

  1. Clearly specify the technology stack and framework requirements
  2. Use project templates to ensure specification consistency
  3. Provide more detailed requirement descriptions

Q: Is the command-line tool unresponsive? A:

  1. Check if OpenCode is installed correctly
  2. Confirm that the MCP server configuration is correct
  3. Try restarting the terminal

For more questions, refer to: Complete FAQ

💬 Technical Discussions

WeChat Technical Exchange Group

WeChat group QR code
Scan the QR code to join the WeChat technical exchange group

🚀 Get started with OpenCode + CloudBase AI Toolkit immediately

Get Started | View Templates | GitHub Repository