Skip to main content

CloudBase basic capabilities MCP access

Supports managing CloudBase basic capabilities via the MCP protocol, including CloudBase environment management, static website deployment, database collection management, and database document operations.

Go to CloudBase Platform to run MCP Server


🚀 Optimized for AI Programming Assistants: Introducing CloudBase-AI-ToolKit

If you are using AI programming tools such as Cursor, VSCode GitHub Copilot, Claude Code, etc., we highly recommend that you directly use CloudBase-AI-ToolKit!

CloudBase-AI-ToolKit is an upper-layer application specifically designed for local IDE development workflows. It encapsulates the underlying capabilities of this project, providing you with a seamless intelligent development experience:

  • 🤖 AI-Powered Instant Deployment: Enable your AI programming assistant not only to write code, but also to directly generate deployable full-stack applications and mini program projects.
  • ☁️ One-Click Cloud Deployment: After developing through conversations with AI in the IDE, deploy applications to Tencent CloudBase with one click, eliminating all tedious configurations.

Simply put, CloudBase-AI-ToolKit is your best choice for local IDE-based AI-driven cloud development. This project (cloudbase-mcp) serves as its core engine.

👉 Go to CloudBase-AI-ToolKit and start your AI cloud development journey!


Features

  • ☁️ CloudBase Environment Management: Provides capabilities such as retrieving all CloudBase environment information, obtaining valid domain name lists for environments, adding and deleting secure domains, as well as retrieving and modifying current environment information.
  • 💻 Database Collection Management: Supports database collection operations such as creating collections, checking existence, updating, retrieving details, listing collections, checking index existence, and querying data distribution.
  • 📒 Database Document Operations: Supports inserting documents into collections, querying documents, updating documents, and deleting documents.
  • 🌍 Static Hosting Management: Enables uploading files to static website hosting, retrieving file lists, deleting files or folders, searching files, binding and unbinding custom domains, obtaining static website configurations, checking domain configurations, and modifying domain configurations.
  • 💻 Temporary File Management: Enables creating files in temporary directories, supporting text content or base64-encoded binary content; reading files from temporary directories, supporting both text and binary files.

Usage Example

Usage Instructions

Remote MCP

This project supports One-Click Deployment to Tencent CloudBase Platform, providing remote SSE access.

☁️ Go to CloudBase Platform to deploy MCP Server

After deployment is complete, refer to the instructions on using MCP in the page to access the MCP Server via remote SSE.

Local MCP

When running in a local client environment that supports MCP, you can also use npx to invoke the cloudbase-mcp tool.

{
"mcpServers": {
"cloudbase-mcp": {
"command": "npx",
"args": ["@cloudbase/cloudbase-mcp"],
"env": {
"TENCENTCLOUD_SECRETID": "Tencent Cloud SecretId",
"TENCENTCLOUD_SECRETKEY": "Tencent Cloud SecretKey",
"TENCENTCLOUD_SESSIONTOKEN": "Tencent Cloud session Token, required only when using temporary keys",
"CLOUDBASE_ENV_ID": "CloudBase environment ID"
}
}
}
}

Environment Variables

  • TENCENTCLOUD_SECRETID and TENCENTCLOUD_SECRETKEY / TENCENTCLOUD_SESSIONTOKEN need to be configured as your SecretId and SecretKey obtained from the Tencent Cloud console (Obtain Tencent Cloud API keys)
  • You need to configure CLOUDBASE_ENV_ID as the environment ID obtained from the CloudBase console. Obtain CloudBase environment ID

🗺️ Feature List

Cloud Development Environment Management

Tool IdentifierFunction DescriptionCore Parameters
listEnvsGet all CloudBase environment informationNone
getEnvAuthDomainsGet the list of authorized domains for the CloudBase environmentNone
createEnvDomainAdd secure domains to the CloudBase environmentdomains (required, array of secure domains)
deleteEnvDomainDelete specified secure domains for the CloudBase environmentdomains (required, array of secure domains)
getEnvInfoGet current CloudBase environment informationNone
updateEnvInfoUpdate the CloudBase environment aliasalias (required, environment alias)

Database Collection Management

Tool IdentifierFunction DescriptionCore Parameters
createCollectionCreate a new CloudBase database collectioncollectionName (required, collection name)
checkCollectionExistsCheck if the CloudBase database collection existscollectionName (required, collection name)
updateCollectionUpdate CloudBase database collection configuration (create or delete indexes)collectionName (required, collection name), options (required, update options, supports creating and deleting indexes)
describeCollectionDescribe the details of the CloudBase database collectioncollectionName (required, collection name)
listCollectionsList CloudBase database collectionsoffset (optional, offset), limit (optional, maximum number of records to return)
checkIndexExistsCheck if the index existscollectionName (required, collection name), indexName (required, index name)
distributionQuery the data distribution of collections in the databaseNone

Database Document Operations

Tool IdentifierFunction DescriptionCore Parameters
insertDocumentsInsert one or more documents into a collectioncollectionName (required, collection name), documents (required, an array of documents to insert, each as a JSON string)
queryDocumentsQuery documents in a collectioncollectionName (required, collection name), query (optional, query conditions, JSON string), projection (optional, field projection for returned results, JSON string), sort (optional, sort conditions, JSON string), limit (optional, maximum number of records to return), offset (optional, number of records to skip)
updateDocumentsUpdate documents in a collectioncollectionName (required, collection name), query (required, query conditions, JSON string), update (required, update content, JSON string), isMulti (optional, whether to update multiple records), upsert (optional, whether to insert if not exists)
deleteDocumentsDelete documents in a collectioncollectionName (required, collection name), query (required, query conditions, JSON string), isMulti (optional, whether to delete multiple records)

Static Hosting Management

Tool IdentifierFunction DescriptionCore Parameters
uploadFilesUpload files to static website hostinglocalPath (optional, local file or folder path), cloudPath (optional, cloud file or folder path), files (optional, multi-file upload configuration), ignore (optional, file ignore pattern)
listFilesList files in static website hostingNone
deleteFilesDelete files or folders in static website hostingcloudPath (required, cloud file or folder path), isDir (optional, whether it is a folder, default is false)
findFilesFind files in static website hostingprefix (required, matching prefix), marker (optional, starting object key marker), maxKeys (optional, maximum number of entries to return per request)
createHostingDomainBind a custom domaindomain (required, custom domain), certId (required, certificate ID)
deleteHostingDomainUnbind a custom domaindomain (required, custom domain)
getWebsiteConfigGet static website configurationNone
tcbCheckResourceCheck domain configurationdomains (required, domain list)
tcbModifyAttributeModify domain configurationdomain (required, domain), domainId (required, domain ID), domainConfig (required, domain configuration)

Temporary File Management

Tool IdentifierFunction DescriptionCore Parameters
createTempFileCreate a file in the temporary directory, supporting text content or base64-encoded binary contentcontent (required, file content, which can be plain text or base64-encoded binary content), isBase64 (optional, whether the content is base64-encoded, default is false), extension (optional, file extension, such as .txt, .png, etc.)
readTempFileRead files in the temporary directory, supporting both text and binary filesfilePath (required, file path), asBase64 (optional, whether to return the content in base64 format, default is false)

🔌 Usage


CloudBase MCP Console