Skip to main content
Glama
phantosmax

CloudStack MCP Server

by phantosmax

resize_volume

Increase or decrease the size of a volume in CloudStack MCP Server by specifying the Volume ID and desired size in GB. Optionally allow shrinking for reduced storage needs.

Instructions

Resize a volume

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesVolume ID
shrinkokNoAllow shrinking
sizeYesNew size in GB

Implementation Reference

  • The main handler function that executes the resize_volume tool by calling the CloudStack client and formatting the response.
    async handleResizeVolume(args: any) {
      const result = await this.cloudStackClient.resizeVolume(args);
      
      return {
        content: [
          {
            type: 'text',
            text: `Resized volume ${args.id}. Job ID: ${result.resizevolumeresponse?.jobid}`
          }
        ]
      };
    }
  • Defines the tool metadata including name, description, and input schema for resize_volume.
    {
      name: 'resize_volume',
      description: 'Resize a volume',
      inputSchema: {
        type: 'object',
        properties: {
          id: {
            type: 'string',
            description: 'Volume ID',
          },
          size: {
            type: 'number',
            description: 'New size in GB',
          },
          shrinkok: {
            type: 'boolean',
            description: 'Allow shrinking',
            default: false,
          },
        },
        required: ['id', 'size'],
        additionalProperties: false,
      },
    },
  • src/server.ts:142-143 (registration)
    Registers the resize_volume tool in the MCP server by dispatching tool calls to the storage handler.
    case 'resize_volume':
      return await this.storageHandlers.handleResizeVolume(args);
  • Low-level wrapper method that sends the resizeVolume command to the CloudStack API.
    async resizeVolume(params: CloudStackParams): Promise<CloudStackResponse> {
      return this.request('resizeVolume', params);
    }
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. 'Resize a volume' implies a mutation operation, but it doesn't describe critical behaviors: whether resizing is immediate or asynchronous, if it requires the volume to be detached or stopped, potential data loss risks (especially with shrinking), permissions needed, or rate limits. This leaves significant gaps for safe and effective use.

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

Conciseness5/5

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

The description is a single, efficient sentence with zero waste—'Resize a volume' is front-loaded and directly states the purpose. Every word earns its place, making it easy to parse quickly.

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

Completeness2/5

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

Given the complexity of a mutation tool with no annotations and no output schema, the description is incomplete. It lacks details on behavioral traits (e.g., side effects, prerequisites), usage context, and expected outcomes. For a tool that modifies infrastructure, this leaves the agent under-informed about risks and proper invocation.

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?

Schema description coverage is 100%, so the schema already documents all parameters (id, shrinkok, size) with clear descriptions. The description adds no additional meaning beyond what's in the schema, such as explaining the implications of 'shrinkok' or units for 'size'. Baseline 3 is appropriate when the schema does the heavy lifting.

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

Purpose4/5

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

The description 'Resize a volume' clearly states the action (resize) and resource (volume) with a specific verb. It distinguishes from siblings like 'create_volume' or 'attach_volume' by focusing on modification rather than creation or attachment. However, it doesn't specify whether this is for increasing or decreasing size, which could help differentiate it further from other volume operations.

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. It doesn't mention prerequisites (e.g., volume must be detached or in a specific state), exclusions, or related tools like 'create_volume' for initial sizing. The agent must infer usage from the tool name and parameters alone.

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

Related 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/phantosmax/cloudstack-mcp-server'

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