Skip to main content
Glama
ahmedselimmansor-ctrl

Alibaba Cloud MCP Server

ecs_list_instances

Retrieve a paginated list of ECS instances in your Alibaba Cloud region, filtered by region ID.

Instructions

List Alibaba Cloud ECS instances in the current region.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
regionIdNoThe region ID (e.g., 'cn-hangzhou'). Defaults to ALIBABA_CLOUD_REGION_ID.
pageSizeNoNumber of results per page. Default 10.

Implementation Reference

  • The handler function for ecs_list_instances. It validates input (regionId, pageSize) using Zod, builds API params, calls Alibaba Cloud's DescribeInstances API, and returns the result as text content.
    if (name === "ecs_list_instances") {
      const parsed = z.object({
        regionId: z.string().default(config.ALIBABA_CLOUD_REGION_ID),
        pageSize: z.number().default(10)
      }).parse(args);
    
      const params = {
        RegionId: parsed.regionId,
        PageSize: parsed.pageSize
      };
    
      const result = await client.request('DescribeInstances', params, requestOption);
      return {
        content: [{ type: "text", text: JSON.stringify(result, null, 2) }]
      };
    }
  • The tool registration definition for ecs_list_instances, including its name, description, and inputSchema (regionId string, pageSize number).
    name: "ecs_list_instances",
    description: "List Alibaba Cloud ECS instances in the current region.",
    inputSchema: {
      type: "object",
      properties: {
        regionId: {
          type: "string",
          description: "The region ID (e.g., 'cn-hangzhou'). Defaults to ALIBABA_CLOUD_REGION_ID."
        },
        pageSize: {
          type: "number",
          description: "Number of results per page. Default 10."
        }
      }
    }
  • src/index.ts:35-35 (registration)
    Registration of all ECS tools (including ecs_list_instances) via registerEcsTools() in the ListToolsRequestSchema handler.
    ...registerEcsTools(),
  • src/index.ts:54-55 (registration)
    Routing of tool calls with 'ecs_' prefix (including ecs_list_instances) to the handleEcsTools function in the CallToolRequestSchema handler.
    if (name.startsWith("ecs_")) {
      return await handleEcsTools(name, args);
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Without annotations, the description must disclose behavior. It only says 'list' implying read-only but does not explicitly confirm safety, pagination details, or rate limits. The pagination parameter (pageSize) is not explained in terms of behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence, no fluff. However, it lacks detail that could be added without sacrificing conciseness, such as mentioning pagination scope.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given full schema coverage and no output schema, description is adequate but leaves gaps: no mention of pagination behavior, default region handling, or return format.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Input schema provides 100% coverage for both parameters with descriptions. The tool description adds no additional semantic value beyond the schema, warranting baseline score.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb (List) and resource (ECS instances) and specifies scope (current region). It effectively distinguishes from sibling tools like ack_list_clusters and rds_list_instances.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives, nor are prerequisites or context mentioned. Usage is purely inferred from the description.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ahmedselimmansor-ctrl/Alibaba_cloud_MCP_server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server