CloudBase (Tencent Cloud Development)
Description
Guide Trae to develop on Tencent CloudBase with the correct order of operations: environment binding → MCP management tools → scenario skill → implementation → review/deploy.
CloudBase covers Web / H5, WeChat Mini Program, cloud functions, CloudRun, document DB / PostgreSQL / MySQL, cloud storage, auth, and built-in AI models.
Usage Scenario
Use this skill when the user:
- Mentions CloudBase, 云开发, TCB, 腾讯云开发, or WeChat Mini Program cloud development
- Asks to scaffold, deploy, or debug a CloudBase Web / Mini Program / CloudRun app
- Needs auth, database, storage, cloud functions, or CloudBase AI model integration
- Wants Trae wired to
@cloudbase/cloudbase-mcp
Do not use for non-CloudBase backends or pure frontend work with no CloudBase dependency.
Preconditions
- Trae can run terminal commands and edit project files
- Prefer enabling CloudBase MCP (see below) before management API work
- User should have a Tencent Cloud / CloudBase account (browser login is prompted by MCP)
Instructions
- Confirm scenario — Web, WeChat Mini Program, CloudRun, database-only, auth-only, or AI model. State which scenario you will follow.
- Ensure CloudBase MCP is available in Trae
- Settings → MCP → Add → Manual:
{
"mcpServers": {
"cloudbase-mcp": {
"command": "npx",
"args": ["-y", "@cloudbase/cloudbase-mcp@latest"],
"env": {}
}
}
}
- On first use, complete browser login / environment selection.
- Bind environment explicitly
- Call
envQuery (or equivalent) to resolve the canonical EnvId.
- Never pass aliases/nicknames directly into SDK init or deploy configs — resolve to full
EnvId first.
- Prefer MCP tools for management work
- Auth providers, DB schema, functions, hosting, CloudRun, storage, security rules: use MCP first.
- Inspect tool schemas before calling; do not invent parameters.
- Load the matching published CloudBase skill before coding
- Main entry: https://github.com/TencentCloudBase/skills (or
npx skills add tencentcloudbase/cloudbase-skills)
- Common ids:
web-development, miniprogram-development, auth-tool-cloudbase, auth-web-cloudbase, cloud-functions, cloudrun-development, postgresql-development-cloudbase, ui-design, cloudbase-platform
- Read the skill fully before writing application code.
- Implementation order
- Resource prep via MCP (providers, collections/tables, permissions) → then frontend/backend code → local verify → deploy.
- Close-out
- Run a CloudBase-aware review when available (
cloudbase-code-review skill).
- Report EnvId, resources touched, and preview/deploy URLs.
Examples
Example 1 — Web app with username/password auth
User: “用云开发做一个带登录的 Web 管理后台”
Agent should:
- Enable CloudBase MCP and bind
EnvId
- Use auth MCP tools to enable username/password (and publishable key) before writing login UI
- Follow
auth-tool-cloudbase then auth-web-cloudbase / web-development
- Deploy static hosting only after auth providers are confirmed
Example 2 — WeChat Mini Program CRUD
User: “小程序云开发读写文档数据库”
Agent should:
- Confirm Mini Program + CloudBase scenario
- Use NoSQL MCP tools /
cloudbase-document-database-in-wechat-miniprogram guidance
- Avoid Web SDK auth patterns in Mini Program code
References
Constraints
- Do not invent CloudBase API paths or MCP tool arguments
- Do not expose API keys /
service_role credentials in frontend code
- After 2–3 failed attempts on the same path, stop and reroute (env, auth domain, permission model, or skill)
1---2name: cloudbase3description: Use when building, deploying, or debugging Tencent CloudBase (腾讯云开发 / TCB) apps in Trae — Web, WeChat Mini Program, cloud functions, CloudRun, auth, NoSQL/PostgreSQL, storage, and built-in AI. Prefer CloudBase MCP tools first, then load published CloudBase skills for scenario details.4---56# CloudBase (Tencent Cloud Development)78## Description910Guide Trae to develop on **Tencent CloudBase** with the correct order of operations: environment binding → MCP management tools → scenario skill → implementation → review/deploy.1112CloudBase covers Web / H5, WeChat Mini Program, cloud functions, CloudRun, document DB / PostgreSQL / MySQL, cloud storage, auth, and built-in AI models.1314## Usage Scenario1516Use this skill when the user:1718- Mentions CloudBase, 云开发, TCB, 腾讯云开发, or WeChat Mini Program cloud development19- Asks to scaffold, deploy, or debug a CloudBase Web / Mini Program / CloudRun app20- Needs auth, database, storage, cloud functions, or CloudBase AI model integration21- Wants Trae wired to `@cloudbase/cloudbase-mcp`2223Do **not** use for non-CloudBase backends or pure frontend work with no CloudBase dependency.2425## Preconditions2627- Trae can run terminal commands and edit project files28- Prefer enabling CloudBase MCP (see below) before management API work29- User should have a Tencent Cloud / CloudBase account (browser login is prompted by MCP)3031## Instructions32331. **Confirm scenario** — Web, WeChat Mini Program, CloudRun, database-only, auth-only, or AI model. State which scenario you will follow.342. **Ensure CloudBase MCP is available in Trae**35 - Settings → MCP → Add → Manual:3637```json38{39 "mcpServers": {40 "cloudbase-mcp": {41 "command": "npx",42 "args": ["-y", "@cloudbase/cloudbase-mcp@latest"],43 "env": {}44 }45 }46}47```4849 - On first use, complete browser login / environment selection.503. **Bind environment explicitly**51 - Call `envQuery` (or equivalent) to resolve the canonical `EnvId`.52 - Never pass aliases/nicknames directly into SDK init or deploy configs — resolve to full `EnvId` first.534. **Prefer MCP tools for management work**54 - Auth providers, DB schema, functions, hosting, CloudRun, storage, security rules: use MCP first.55 - Inspect tool schemas before calling; do not invent parameters.565. **Load the matching published CloudBase skill before coding**57 - Main entry: https://github.com/TencentCloudBase/skills (or `npx skills add tencentcloudbase/cloudbase-skills`)58 - Common ids: `web-development`, `miniprogram-development`, `auth-tool-cloudbase`, `auth-web-cloudbase`, `cloud-functions`, `cloudrun-development`, `postgresql-development-cloudbase`, `ui-design`, `cloudbase-platform`59 - Read the skill fully before writing application code.606. **Implementation order**61 - Resource prep via MCP (providers, collections/tables, permissions) → then frontend/backend code → local verify → deploy.627. **Close-out**63 - Run a CloudBase-aware review when available (`cloudbase-code-review` skill).64 - Report EnvId, resources touched, and preview/deploy URLs.6566## Examples6768### Example 1 — Web app with username/password auth6970**User:** “用云开发做一个带登录的 Web 管理后台”7172**Agent should:**73741. Enable CloudBase MCP and bind `EnvId`752. Use auth MCP tools to enable username/password (and publishable key) before writing login UI763. Follow `auth-tool-cloudbase` then `auth-web-cloudbase` / `web-development`774. Deploy static hosting only after auth providers are confirmed7879### Example 2 — WeChat Mini Program CRUD8081**User:** “小程序云开发读写文档数据库”8283**Agent should:**84851. Confirm Mini Program + CloudBase scenario862. Use NoSQL MCP tools / `cloudbase-document-database-in-wechat-miniprogram` guidance873. Avoid Web SDK auth patterns in Mini Program code8889## References9091- Docs: https://docs.cloudbase.net/ai/cloudbase-ai-toolkit/ai-agent-plugins92- Toolkit source: https://github.com/TencentCloudBase/CloudBase-AI-Toolkit93- Open Plugin / skills package: https://github.com/TencentCloudBase/cloudbase-plugin94- Published skills: https://github.com/TencentCloudBase/skills9596## Constraints9798- Do not invent CloudBase API paths or MCP tool arguments99- Do not expose API keys / `service_role` credentials in frontend code100- After 2–3 failed attempts on the same path, stop and reroute (env, auth domain, permission model, or skill)