ali-cloud-rds-interface-mcp-server
Facilitates interaction with Alibaba Cloud's Relational Database Service (RDS) ecosystem. It standardizes access for provisioning, monitoring database entities, retrieving operational metrics, and tuning configuration settings via a unified MCP gateway.
Author

aliyun
Quick Info
Actions
Tags
Alibaba Cloud RDS API Gateway MCP Module
This MCP server leverages the RDS OpenAPI specification for interaction.
Prerequisites for Operation
- Obtain the
uvpackage installer from Astral's official distribution or directly from the source repository. - Utilize
uv python install 3.12to set up the requisite Python runtime environment. - Secure valid Alibaba Cloud credentials possessing the necessary permissions to manage RDS resources.
Initial Setup Guide
Method 1: Utilizing [cherry-studio] (Recommended Pathway)
- Download and install the Cherry Studio application suite.
- Adhere to the Cherry Studio documentation to install the dependency manager (
uv), which is mandatory for the MCP runtime context. - Configure and integrate the RDS MCP component following the setup guidance provided in the advanced documentation. Importing the configuration is streamlined using the JSON snippet below. Remember to substitute
$you_access_idand$you_access_keywith your actual Alibaba Cloud Access Key ID and Secret.
Note: You might observe a transient error message during import, such as
xxx settings.mcp.addServer.importFrom.connectionFailed; this specific message can be safely disregarded.
5 { "mcpServers": { "rds-openapi": { "name": "rds-openapi", "type": "stdio", "description": "", "isActive": true, "registryUrl": "", "command": "uvx", "args": [ "alibabacloud-rds-openapi-mcp-server@latest" ], "env": { "ALIBABA_CLOUD_ACCESS_KEY_ID": "$you_access_id", "ALIBABA_CLOUD_ACCESS_KEY_SECRET": "$you_access_key" } } } }
-
Finalize the process by activating the MCP service via the interface toggle.
-
Employ the provided prompt templates for an optimized interaction experience.
Method 2: Direct Cline Execution
Establish your environment variables and then initiate the MCP server process. shell
Environment Setup
export SERVER_TRANSPORT=sse; export ALIBABA_CLOUD_ACCESS_KEY_ID=$you_access_id; export ALIBABA_CLOUD_ACCESS_KEY_SECRET=$you_access_key; export ALIBABA_CLOUD_SECURITY_TOKEN=$you_sts_security_token; # Optional: Needed if utilizing an STS Token export API_KEY=$you_mcp_server_api_key; # Optional: Enforces API Key validation for incoming requests post-configuration
Server Launch Command
uvx alibabacloud-rds-openapi-mcp-server@latest
Upon successful launch, you will observe output similar to this: shell INFO: Started server process [91594] INFO: Waiting for application startup. INFO: Application startup complete. INFO: Uvicorn running on http://0.0.0.0:8000 (Press CTRL+C to quit)
Subsequently, configure your Cline client connection: shell remote_server = "http://127.0.0.1:8000/sse";
Should you receive a
401 Incorrect API key providederror when interfacing with Qwen, consult the official documentation for resolution steps.
Method 3: Claude Integration
Clone the repository directly from GitHub: shell git clone https://github.com/aliyun/alibabacloud-rds-openapi-mcp-server.git
Integrate the following configuration snippet into your MCP client's settings file: 5 { "mcpServers": { "rds-openapi-mcp-server": { "command": "uv", "args": [ "--directory", "/path/to/alibabacloud-rds-openapi-mcp-server/src/alibabacloud_rds_openapi_mcp_server", "run", "server.py" ], "env": { "ALIBABA_CLOUD_ACCESS_KEY_ID": "access_id", "ALIBABA_CLOUD_ACCESS_KEY_SECRET": "access_key", "ALIBABA_CLOUD_SECURITY_TOKEN": "sts_security_token", // optional, required when using STS Token } } } }
Functional Components
OpenAPI Interface Modules
add_tags_to_db_instance: Associates arbitrary metadata tags with a specified RDS entity.allocate_instance_public_connection: Establishes external internet accessibility for an RDS instance.attach_whitelist_template_to_instance: Binds a predefined network access rule set to an RDS instance.create_db_instance: Provisions a new relational database instance.create_db_instance_account: Generates user credentials for database access.describe_all_whitelist_template: Retrieves the complete inventory of configured network access templates.describe_available_classes: Fetches supported instance types and permissible storage capacities.describe_available_zones: Lists geographic availability zones suitable for RDS deployment.describe_bills: Summarizes billing and consumption records across all managed product resources for a given period.describe_db_instance_accounts: Mass retrieves credential details for specified database instances.describe_db_instance_attribute: Fetches the comprehensive configuration details of a single instance.describe_db_instance_databases: Batch retrieves the list of user databases hosted on selected instances.describe_db_instance_ip_allowlist: Queries the configured IP address ingress rules for multiple instances.describe_db_instance_net_info: Batch retrieves detailed network connectivity information.describe_db_instance_parameters: Retrieves current configuration parameter sets for targeted instances.describe_db_instance_performance: Queries real-time operational metrics and telemetry data.describe_db_instances: Lists and filters existing database instances.describe_error_logs: Fetches diagnostic error output from an instance.describe_instance_linked_whitelist_template: Queries which access templates are presently associated with an instance.describe_monitor_metrics: Retrieves advanced performance and diagnostic data via the DAS (Database Autonomy Service) endpoint.describe_slow_log_records: Extracts logs detailing queries exceeding predefined execution time thresholds.describe_sql_insight_statistic: Analyzes SQL execution statistics, focusing on aggregate cost, frequency, and associated user accounts.describe_vpcs: Retrieves the list of Virtual Private Clouds configured.describe_vswitches: Retrieves the list of VSwitch subnets within VPCs.modify_security_ips: Updates the IP whitelist governing instance access.get_current_time: Retrieves the synchronized system time.modify_db_instance_description: Updates the human-readable label for an RDS instance.modify_db_instance_spec: Scales the computational resources (e.g., vCPU, memory) of an instance.modify_parameter: Adjusts specific runtime settings for the database engine.restart_db_instance: Initiates a controlled reboot of the database server.
SQL Execution Modules
A temporary, read-only database credential is automatically provisioned, used for query execution, and subsequently revoked. This mechanism mandates that the MCP Server must possess network connectivity to the target instance.
explain_sql: Executes theEXPLAINcommand on provided SQL, returning the query plan analysis.show_engine_innodb_status: ExecutesSHOW ENGINE INNODB STATUSand reports the output.show_create_table: ExecutesSHOW CREATE TABLEfor a specified table and returns the DDL statement.query_sql: Executes arbitrary, non-modifying SQL statements and returns the result set.
Operational Tool Groupings
Toolsets serve to consolidate related MCP tools, allowing users to activate only the necessary functionality during server initialization. Configuration can be set via:
- Command Line Interface: Using the
--toolsetsflag. - Environment Variable: Setting the
MCP_TOOLSETSvariable.
Enumerated Toolsets
This list details the predefined groupings and their intended scope:
-
rds: Activates all tools associated with the standard, managed RDS offering.
-
rds_custom_read: Enables read-only operational tools specifically for RDS Custom deployments.
-
rds_custom_all: Enables the full spectrum of read and write capabilities for RDS Custom deployments.
Syntax for Specification
Toolset names must be provided as a comma-separated list without extraneous whitespace:
rds,rds_custom_all
Usage Examples
bash
Loading a single toolset
--toolsets rds
Loading multiple, distinct toolsets
--toolsets rds,rds_mssql_custom
Using the environment variable mechanism
export MCP_TOOLSETS=rds,rds_custom_all
Default Configuration
If no toolset parameter is supplied during startup, the system defaults to loading the rds group automatically.
Supplementary Resources
No external resources are currently indexed or referenced.
Guidance Prompts
markdown
Persona
Your designation is the Alibaba Cloud RDS Expert Copilot, focused on delivering high-efficacy technical assistance and resolutions pertaining to RDS (Relational Database Service). Your primary directive is to expedite problem resolution through meticulous decomposition, accurate invocation of the appropriate toolset, and precise temporal calculation where needed.
Core Competencies
Competency 1: Requirement Disaggregation and Analysis
- Systematically break down complex user inquiries to distill fundamental needs and the sequence of necessary commands or operations.
- Present task workflows in a structured, tabular format to maintain clarity throughout the solution path.
Competency 2: RDS MCP Tool Orchestration
- Demonstrate mastery in leveraging the RDS MCP interface to fetch data or execute administrative tasks.
- Tool deployment must be directly traceable to the logical steps identified in the task decomposition and aligned with stated user objectives.
- Select the correct MCP utility (e.g., metric retrieval, diagnostic procedures, configuration management) based on the specific requirement.
Competency 3: Temporal Reasoning and Conversion
- Accurately interpret relative time expressions (e.g., "last 24 hours," "yesterday," "this morning").
- Convert these relative terms into definitive, actionable time windows or UTC timestamps to satisfy data retrieval or operational constraints.
Operational Directives
- Sequence Mandate: Task decomposition must always precede any solution steps.
- Justification Rule: Every MCP command execution requires clear logical justification derived from the decomposed tasks.
- Temporal Rigor: Queries involving time must utilize exact, calculated boundary points.
- Domain Focus: Restrict all discussion strictly to Alibaba Cloud RDS technical support and operations.
- Risk Aversion: Ensure that all proposed actions pose no threat to the integrity or availability of customer database systems.
Illustrative Scenarios
MyDBA Integration
Alibaba Cloud Database MyDBA Agent(README.md) - RDS Acquisition Services
- RDS Diagnostic Services
Contribution Guidelines
We warmly welcome external contributions. Please utilize the standard Pull Request workflow:
1. Fork the primary repository.
2. Create a dedicated feature branch (git checkout -b feature/amazing-feature).
3. Commit staged changes (git commit -m 'Add some amazing feature').
4. Push the new branch upstream (git push origin feature/amazing-feature).
5. Submit a formal Pull Request for review.
Licensing Information
This software is distributed under the terms of the Apache 2.0 License.
Communication Channel
For inquiries or support, please join our DingTalk community via ID: 106730017609 WIKIPEDIA NOTE: Cloud computing, as defined by ISO, signifies "a model for enabling ubiquitous, convenient, on-demand network access to a shared pool of configurable computing resources (e.g., networks, servers, storage, applications, and services) that can be rapidly provisioned and released with minimal management effort or service provider interaction."
== Core Tenets == In 2011, the National Institute of Standards and Technology (NIST) established five fundamental attributes defining cloud systems. These are quoted verbatim from NIST standards:
On-demand self-service: "A consumer can unilaterally provision computing capabilities, such as server time and network storage, as needed automatically without requiring human interaction with each service provider." Broad network access: "Capabilities are available over the network and accessed through standard mechanisms that promote use by heterogeneous thin or thick client platforms (e.g., mobile phones, tablets, laptops, and workstations)." Resource pooling: " The provider's computing resources are pooled to serve multiple consumers using a multi-tenant model, with different physical and virtual resources dynamically assigned and reassigned according to consumer demand." Rapid elasticity: "Capabilities can be elastically provisioned and released, in some cases automatically, to scale rapidly outward and inward commensurate with demand. To the consumer, the capabilities available for provisioning often appear unlimited and can be appropriated in any quantity at any time." Measured service: "Cloud systems automatically control and optimize resource use by leveraging a metering capability at some level of abstraction appropriate to the type of service (e.g., storage, processing, bandwidth, and active user accounts). Resource usage can be monitored, controlled, and reported, providing transparency for both the provider and consumer of the utilized service. By 2023, the International Organization for Standardization (ISO) had expanded and refined the list.
== Historical Context ==
The conceptual roots of cloud computing trace back to the 1960s, marked by the popularization of time-sharing concepts through remote job entry (RJE). During this era, the primary operational model involved centralized "data centers" where users submitted tasks to operators managing large mainframes. This period was characterized by intensive R&D into democratizing access to substantial computational power via time-sharing, optimizing infrastructure, platform layers, and applications to boost overall end-user efficiency. The derivation of the "cloud" nomenclature for networked services is generally attributed to 1994, when General Magic employed it to describe the conceptual domain where mobile agents operating in the Telescript environment could traverse. David Hoffman, a specialist in communications at General Magic, is credited with adapting this term from its established usage within telecommunications and networking contexts. The phrase "cloud computing" gained widespread recognition in 1996 following the drafting of a strategic business plan for future internet capabilities by Compaq Computer Corporation. The organization aimed to transcend limitations
