Skip to main content
Glama
phantosmax

CloudStack MCP Server

by phantosmax

scale_virtual_machine

Adjust the service offering of a virtual machine by specifying its ID and the desired service offering ID to scale resources effectively on the CloudStack MCP Server.

Instructions

Scale virtual machine (change service offering)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesVM ID to scale
serviceofferingidYesNew service offering ID

Implementation Reference

  • The main handler function that executes the scale_virtual_machine tool. It calls the CloudStackClient to scale the VM and returns a formatted text response with the job ID.
    async handleScaleVirtualMachine(args: any) {
      const result = await this.cloudStackClient.scaleVirtualMachine(args);
      
      return {
        content: [
          {
            type: 'text',
            text: `Scaled virtual machine ${args.id}. Job ID: ${result.scalevirtualmachineresponse?.jobid}`
          }
        ]
      };
    }
  • Tool schema definition including name, description, and input validation schema for the scale_virtual_machine tool.
    {
      name: 'scale_virtual_machine',
      description: 'Scale virtual machine (change service offering)',
      inputSchema: {
        type: 'object',
        properties: {
          id: {
            type: 'string',
            description: 'VM ID to scale',
          },
          serviceofferingid: {
            type: 'string',
            description: 'New service offering ID',
          },
        },
        required: ['id', 'serviceofferingid'],
        additionalProperties: false,
      },
    },
  • src/server.ts:122-123 (registration)
    Registration in the MCP server switch statement that dispatches calls to the scale_virtual_machine handler.
    case 'scale_virtual_machine':
      return await this.vmHandlers.handleScaleVirtualMachine(args);
  • Helper method in CloudStackClient that wraps the API request for scaling a virtual machine.
    async scaleVirtualMachine(params: CloudStackParams): Promise<CloudStackResponse> {
      return this.request('scaleVirtualMachine', params);
    }
  • src/server.ts:97-99 (registration)
    Tool list registration via allToolDefinitions which includes the scale_virtual_machine tool schema.
    return {
      tools: allToolDefinitions,
    };
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It mentions 'scale' and 'change service offering' which implies a mutation operation, but doesn't specify whether this requires downtime, affects billing, has permission requirements, or what the expected outcome is. For a mutation tool with zero annotation coverage, this leaves significant behavioral gaps.

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 extremely concise - a single phrase that communicates the core function without any wasted words. It's front-loaded with the essential information and doesn't contain unnecessary elaboration.

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?

For a mutation tool with no annotations and no output schema, the description is insufficient. It doesn't explain what 'scale' means operationally, what happens during the scaling process, whether there are limitations or side effects, or what the tool returns. The context signals show this is a 2-parameter tool with good schema coverage, but the behavioral aspects are completely undocumented.

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%, with both parameters clearly documented in the schema. The description doesn't add any parameter-specific information beyond what's already in the schema (VM ID and service offering ID). This meets the baseline expectation when schema coverage is complete.

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 clearly states the verb ('scale') and resource ('virtual machine'), with additional clarification about changing service offering. It distinguishes from siblings like 'change_service_offering_virtual_machine' by using different terminology, though the distinction isn't explicitly explained. The purpose is specific and actionable.

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?

The description provides no guidance on when to use this tool versus alternatives like 'change_service_offering_virtual_machine' (which appears to be a sibling with similar function) or other VM management tools. There's no mention of prerequisites, constraints, or typical use cases.

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