hcloud-mcp-server
Allows AI agents to interact with Huawei Cloud services by executing hcloud CLI commands, with support for help-based discovery and safety checks for destructive operations.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@hcloud-mcp-server list all ECS instances in my account"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
hcloud-mcp-server
An MCP (Model Context Protocol) server that exposes the Huawei Cloud CLI (hcloud) as a single tool that AI assistants can navigate interactively — just like a human would.
Usage Options
MCP server: It maps the main hcloud functions as MCP functions and instructs for the use of --help in order to get the other functions, it uses hcloud cli in the background and as such, hcloud cli must be set up beforehand with
hcloud configure initand configure obs as well. It works faster than the CLI + Skill vertionCLI + Skill: As stated by Microsoft: Modern coding agents increasingly favor CLI–based workflows exposed as SKILLs over MCP because CLI invocations are more token-efficient: they avoid loading large tool schemas and verbose accessibility trees into the model context, allowing agents to act through concise, purpose-built commands.
It is recommended to uses the CLI + Skill option, you'll only need to copy the skills folder to your tool's skills folder.
.opencode/skills or .claude/skills
Related MCP server: Huawei MCP Server
How It Works
The server registers one tool: hcloud_cli. The AI navigates hcloud using --help at each level:
hcloud_cli("--help") → list all services
hcloud_cli("IAM --help") → list IAM operations
hcloud_cli("IAM ListCustomPolicies --help") → show parameters
hcloud_cli("IAM ListCustomPolicies") → executeThis mirrors how a human discovers and uses the CLI, requires only 1 tool definition in the LLM context (~300 tokens), and works within any model's context window.
Features
Single tool — minimal context footprint, works with any model size
Interactive discovery — AI navigates
--helpmenus naturallySafety layer — destructive operations (Delete, Detach, Revoke, etc.) require
confirm=true; default is dry-run modeStructured output — JSON output forced automatically (
--cli-output=json)Configurable — timeout, binary path, safety settings
Requirements
Python 3.10+
hcloud CLI installed and configured with authentication
Installation
pip install hcloud-mcp-serverOr from source:
git clone <repo-url>
cd hcloud-mcp-server
pip install -e .Verify:
hcloud-mcp --helpRunning
# Start the MCP server (stdio transport)
hcloud-mcp
# With a config file
hcloud-mcp --config /path/to/config.json
# With debug logging
hcloud-mcp --debugConfiguration
Config file
Create a JSON config file (see config.example.json):
{
"execution": {
"timeout_seconds": 30,
"cli_output": "json",
"hcloud_binary": "hcloud"
}
}Environment variables
Variable | Description |
| Path to config JSON file |
Tool Reference
hcloud_cli
Parameter | Type | Required | Description |
| string | Yes | hcloud CLI arguments (everything after |
| boolean | No | Set |
Navigation flow:
command="--help"— list all available servicescommand="<Service> --help"— list operations for a servicecommand="<Service> <Operation> --help"— show parameters and descriptionscommand="<Service> <Operation> --param1=value1"— execute the operation
Parameter format: Always use --param=value (equals sign required by hcloud).
Safety: Operations containing Delete, Remove, Revoke, Detach, Disassociate, Cancel, or Force are classified as destructive. Without confirm=true, they run with --dryrun first.
Adding to AI Tools
The hcloud MCP server uses standard stdio transport, compatible with any MCP client.
opencode
Add to ~/.opencode/opencode.json:
{
"mcp": {
"hcloud": {
"type": "local",
"command": ["hcloud-mcp"],
"enabled": true
}
}
}Claude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
{
"mcpServers": {
"hcloud": {
"command": "hcloud-mcp",
"args": []
}
}
}Cursor
Add to ~/.cursor/mcp.json:
{
"mcpServers": {
"hcloud": {
"command": "hcloud-mcp",
"args": []
}
}
}VS Code (GitHub Copilot)
Add to .vscode/mcp.json:
{
"servers": {
"hcloud": {
"type": "stdio",
"command": "hcloud-mcp",
"args": []
}
}
}Windsurf
Add to ~/.windsurf/mcp.json:
{
"mcpServers": {
"hcloud": {
"command": "hcloud-mcp",
"args": []
}
}
}Goose
Add to ~/.config/goose/config.yaml:
extensions:
hcloud:
type: stdio
command: hcloud-mcp
args: []Any MCP Client (generic)
Setting | Value |
Command |
|
Args |
|
Transport | stdio |
Example AI Session
User: How many custom IAM policies do I have?
AI: Let me check your IAM policies.
→ hcloud_cli(command="--help")
[sees IAM in the service list]
→ hcloud_cli(command="IAM --help")
[sees ListCustomPolicies in the operations list]
→ hcloud_cli(command="IAM ListCustomPolicies --help")
[sees no required parameters]
→ hcloud_cli(command="IAM ListCustomPolicies")
{ "total_number": 2, "roles": [...] }
AI: You have 2 custom IAM policies.User: Delete the policy with ID abc123
AI: This is a destructive operation. Let me run it in dry-run mode first.
→ hcloud_cli(command="IAM DeleteCustomPolicy --role_id=abc123")
⚠️ DRY RUN — no changes made.
Set confirm=true to execute for real.
→ hcloud_cli(command="IAM DeleteCustomPolicy --role_id=abc123", confirm=true)
✅ Executed (confirmed destructive operation):
{ "message": "Delete success" }
AI: The policy has been deleted.Development
# Install in editable mode
pip install -e .
# Run tests
pytest tests/ -v
# Run with debug logging
hcloud-mcp --debugTroubleshooting
Server fails to start:
Ensure
hcloudis installed and in PATH:which hcloudVerify auth:
hcloud IAM ListCustomPolicies
Tool calls return errors:
Check hcloud profile:
hcloud configure listEnable debug logging:
hcloud-mcp --debug
AI doesn't know how to use the tool:
The tool description includes navigation instructions
Remind the AI: "Use hcloud_cli with --help to discover operations"
Available Tools
91 toolshcloud_cliA
Huawei Cloud CLI (hcloud) terminal interface.
Navigate the CLI using --help to discover operations and parameters:
--help— list all available services<Service> --help— list operations for a service (e.g.,IAM --help)<Service> <Operation> --help— show parameters for an operation (e.g.,IAM ListCustomPolicies --help)<Service> <Operation> --param1=value1 --param2=value2— execute an operation
The parameter format is always --param=value (equals sign required).
JSON output is forced automatically (--cli-output=json).
For destructive operations (Delete, Remove, Revoke, Detach, etc.), set confirm=true to execute. Without confirmation, the command runs in --dryrun mode first.
OBS (Object Storage Service) uses obsutil with a different format:
obs help— list all OBS commandsobs help <command>— show help for a specific command (e.g.,obs help ls)obs <command> [args...] [options...]— execute an OBS commandUse
--cli-region=<region>to specify the region (translated to the OBS endpoint automatically)OBS output is plain text (not JSON)
For OBS destructive commands that support dry-run (cp, mv, sync), the command runs with -dryRun unless confirmed
For OBS destructive commands without dry-run support (rm, abort, mb, chattri, bucketpolicy, lifecycle), you must set confirm=true to execute
Inputs: command (required), confirm.
hcloud_list_addon_instancesB
List installed add-ons in a CCE cluster
Inputs: region (required), cluster_id (required).
hcloud_list_agenciesB
List IAM agencies (trust relationships)
Inputs: no named parameters.
hcloud_list_alarm_rulesC
List CES alarm rules (v2 API, more complete)
Inputs: region (required), limit.
hcloud_list_alarmsC
List CES (Cloud Eye) alarms
Inputs: region (required), limit.
hcloud_list_availability_zonesA
List availability zones for ECS
Inputs: region (required).
hcloud_list_bandwidthsD
List bandwidths
Inputs: region (required), limit.
hcloud_list_cce_clustersB
List CCE (Kubernetes) clusters
Inputs: region (required), status.
hcloud_list_cce_nodesC
List nodes in a CCE cluster
Inputs: region (required), cluster_id (required).
hcloud_list_dcs_available_zonesB
List available availability zones for DCS (Redis)
Inputs: region (required).
hcloud_list_dcs_flavorsB
List available DCS (Redis) instance flavors/specs
Inputs: region (required).
hcloud_list_dcs_instancesC
List DCS (Redis) instances
Inputs: region (required), limit.
hcloud_list_dds_flavorsB
List available DDS (MongoDB) instance flavors/specs
Inputs: region (required), engine.
hcloud_list_dds_instancesB
List DDS (MongoDB) instances
Inputs: region (required), limit.
hcloud_list_dds_storage_typesB
List available DDS (MongoDB) storage types
Inputs: region (required), engine.
hcloud_list_dns_recordsetsB
List DNS record sets in a zone
Inputs: region (required), zone_id (required), limit.
hcloud_list_dns_zonesC
List DNS zones
Inputs: region (required), type, limit.
hcloud_list_domainsB
List authenticated IAM domains
Inputs: no named parameters.
hcloud_list_eip_quotasB
List EIP resource quotas
Inputs: region (required).
hcloud_list_elb_flavorsC
List available ELB flavor specifications
Inputs: region (required).
hcloud_list_flavorsC
List available ECS instance flavors/specs
Inputs: region (required), availability_zone.
hcloud_list_groupsB
List IAM user groups
Inputs: limit.
hcloud_list_health_monitorsC
List ELB health monitors
Inputs: region (required), limit.
hcloud_list_imagesA
List available IMS images (essential for finding image_ref for ECS/CCE/AS)
Inputs: region (required), imagetype, os_type, platform, +3 more.
hcloud_list_keypairsB
List SSH key pairs
Inputs: region (required).
hcloud_list_kms_key_detailB
Get details of a specific KMS key (state, creation date, etc.)
Inputs: region (required), key_id (required).
hcloud_list_kms_keysB
List KMS encryption keys
Inputs: region (required), limit.
hcloud_list_l7_policiesB
List ELB URL-based routing policies
Inputs: region (required), listener_id, limit.
hcloud_list_listenersC
List ELB listeners
Inputs: region (required), loadbalancer_id, limit.
hcloud_list_load_balancersC
List ELB load balancers
Inputs: region (required), limit.
hcloud_list_membersB
List backend members in an ELB pool
Inputs: region (required), pool_id (required), limit.
hcloud_list_metricsC
List CES (Cloud Eye) metrics
Inputs: region (required), namespace, limit.
hcloud_list_nat_gateway_dnat_rulesB
List DNAT rules on a NAT gateway
Inputs: region (required), nat_gateway_id, limit.
hcloud_list_nat_gatewaysC
List NAT gateways
Inputs: region (required), limit.
hcloud_list_nat_gateway_snat_rulesB
List SNAT rules on a NAT gateway
Inputs: region (required), nat_gateway_id, limit.
hcloud_list_node_poolsB
List node pools in a CCE cluster
Inputs: region (required), cluster_id (required).
hcloud_list_os_versionsA
List available IMS OS versions (key for image selection)
Inputs: region (required).
hcloud_list_policiesB
List IAM policies (system and custom)
Inputs: limit.
hcloud_list_poolsB
List ELB backend server groups (pools)
Inputs: region (required), limit.
hcloud_list_projectsB
List IAM projects
Inputs: no named parameters.
hcloud_list_public_ipsC
List elastic public IPs
Inputs: region (required), limit.
hcloud_list_rds_backupsC
List RDS backups
Inputs: region (required), instance_id (required), limit.
hcloud_list_rds_datastoresB
List available RDS DB engine versions
Inputs: region (required), database_name (required).
hcloud_list_rds_flavorsC
List RDS instance flavor/spec options
Inputs: region (required), database_name (required), version_name.
hcloud_list_rds_instancesC
List RDS database instances
Inputs: region (required), limit.
hcloud_list_rds_storage_typesA
List supported RDS storage types per engine/version
Inputs: region (required), database_name (required), version_name (required).
hcloud_list_route_tablesC
List route tables
Inputs: region (required), vpc_id, limit.
hcloud_list_scaling_configsC
List AS (Auto Scaling) configurations
Inputs: region (required), limit.
hcloud_list_scaling_groupsC
List AS (Auto Scaling) groups
Inputs: region (required), limit.
hcloud_list_scaling_instancesB
List instances currently in AS groups
Inputs: region (required), scaling_group_id (required).
hcloud_list_scaling_policiesC
List AS (Auto Scaling) policies
Inputs: region (required), scaling_group_id (required), limit.
hcloud_list_security_group_rulesC
List security group rules
Inputs: region (required), security_group_id, limit.
hcloud_list_security_groupsC
List security groups
Inputs: region (required), limit.
hcloud_list_server_block_devicesC
List block devices (volumes) attached to an ECS server
Inputs: region (required), server_id (required).
hcloud_list_server_interfacesC
List network interfaces attached to an ECS server
Inputs: region (required), server_id (required).
hcloud_list_serversC
List ECS cloud servers with optional filters
Inputs: region (required), name, status, flavor_id, +2 more.
hcloud_list_smn_subscriptionsC
List SMN subscriptions
Inputs: region (required), topic_urn, limit.
hcloud_list_smn_topicsB
List SMN (Simple Message Notification) topics
Inputs: region (required), limit, offset.
hcloud_list_snapshotsB
List EVS volume snapshots
Inputs: region (required), limit.
hcloud_list_subnetsC
List subnets
Inputs: region (required), vpc_id, limit.
hcloud_list_user_policiesA
List policies attached to an IAM user
Inputs: user_id (required).
hcloud_list_usersC
List IAM users
Inputs: limit.
hcloud_list_volumesC
List EVS disk volumes
Inputs: region (required), limit.
hcloud_list_volume_typesC
List available EVS volume types
Inputs: region (required).
hcloud_list_vpcsC
List VPCs in the region
Inputs: region (required), limit, offset.
hcloud_obs_catB
View content of a text object in OBS
Inputs: region (required), bucket (required), key (required).
hcloud_obs_lsB
List OBS buckets or objects in a bucket
Inputs: region (required), bucket, prefix, limit, +1 more.
hcloud_obs_statB
Show properties of an OBS bucket or object
Inputs: region (required), bucket (required), key.
hcloud_show_cce_clusterB
Get details of a specific CCE cluster
Inputs: region (required), cluster_id (required).
hcloud_show_dcs_instanceB
Get details of a specific DCS (Redis) instance
Inputs: region (required), instance_id (required).
hcloud_show_dns_zoneB
Get details of a specific DNS zone
Inputs: region (required), zone_id (required), zone_type.
hcloud_show_imageA
Get details of a specific IMS image (min_ram, min_disk, status)
Inputs: region (required), image_id (required).
hcloud_show_image_quotasC
Show IMS image resource quotas
Inputs: region (required).
hcloud_show_load_balancerB
Get details of a specific load balancer
Inputs: region (required), loadbalancer_id (required).
hcloud_show_load_balancer_topologyA
Show load balancer topology tree (listeners, pools, members)
Inputs: region (required), loadbalancer_id (required).
hcloud_show_metric_dataC
Show CES (Cloud Eye) metric data points
Inputs: region (required), namespace (required), metric_name (required), dim_0 (required), +4 more.
hcloud_show_nat_gatewayB
Get details of a specific NAT gateway
Inputs: region (required), nat_gateway_id (required).
hcloud_show_node_poolB
Get details of a specific CCE node pool
Inputs: region (required), cluster_id (required), nodepool_id (required).
hcloud_show_public_ipC
Get details of a specific elastic public IP
Inputs: region (required), publicip_id (required).
hcloud_show_quotaB
Show VPC resource quotas
Inputs: region (required).
hcloud_show_scaling_configA
Get details of a specific AS configuration
Inputs: region (required), scaling_configuration_id (required).
hcloud_show_scaling_groupC
Get details of a specific AS group
Inputs: region (required), scaling_group_id (required).
hcloud_show_scaling_policyA
Get details of a specific AS policy
Inputs: region (required), scaling_policy_id (required).
hcloud_show_security_groupB
Get details of a specific security group
Inputs: region (required), security_group_id (required).
hcloud_show_serverB
Get details of a specific ECS server
Inputs: region (required), server_id (required).
hcloud_show_server_limitsA
Show ECS quota/limits for the tenant
Inputs: region (required).
hcloud_show_snapshotB
Get details of a specific EVS snapshot
Inputs: region (required), snapshot_id (required).
hcloud_show_subnetC
Get details of a specific subnet
Inputs: region (required), subnet_id (required).
hcloud_show_userA
Get details of a specific IAM user
Inputs: user_id (required).
hcloud_show_volumeC
Get details of a specific EVS volume
Inputs: region (required), volume_id (required).
hcloud_show_vpcB
Get details of a specific VPC
Inputs: region (required), vpc_id (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 91 tools
Most tools target distinct Huawei Cloud resources with clear names and descriptions. The only minor overlap is between 'list_alarm_rules' and 'list_alarms', which could cause confusion. Otherwise, each tool has a unique purpose.
All tools follow a strict 'hcloud_<action>_<resource>' pattern with snake_case. The actions are 'list_', 'show_', 'cli', and 'obs_*'. This consistency allows an agent to predict tool names easily.
With 91 tools, the server is excessively large. Although it aims to wrap the entire Huawei Cloud CLI, many tools are redundant patterns (e.g., separate list and show for each resource). This high count likely overwhelms agents and increases selection difficulty.
The tool set is heavily read-only, covering only list and show operations for numerous resources. There are no dedicated create, update, or delete tools; mutation must be done via the generic 'hcloud_cli' tool, which is unstructured and error-prone. This is a significant gap for cloud management.
Maintenance
Related MCP Connectors
MCP server that lets your AI assistant build and deploy apps, hosting each one at a live URL.
MCP server for AI dialogue using various LLM models via AceDataCloud
MCP server for AI agents to plan, verify, and deploy Cloudflare-native apps.
MCP server for your apps' tools and custom tools, plus hosted AI agents and approval-gated workflows
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceAn MCP server that lets AI assistants safely inspect and operate on Kubernetes clusters through natural conversation.MIT
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol server that provides secure, controlled access to Huawei Cloud services (ECS, OBS, GaussDB, etc.) for AI assistants, enabling cloud resource management through conversational workflows.50Apache 2.0
- AlicenseNot gradedqualityCmaintenanceUniversal MCP server that wraps any CLI tool, enabling AI assistants to run commands via natural language.1MIT
- FlicenseNot gradedqualityCmaintenanceMulti-cloud MCP server that exposes cloud AI models as tools for AI CLI agents, supporting streaming, conversation history, parallel multi-model queries, and dynamic model discovery.2-