Skip to main content
Glama

Calculate plan change

calculate_plan_change
Read-onlyIdempotent

Preview a VPSnet plan change without payment, showing the new and current expiration dates and whether an upgrade or downgrade shortens or extends the service.

Instructions

Preview a plan change. No payment is taken: the unused value of the current plan is converted at the new plan's price, so an upgrade moves the expiry EARLIER and a downgrade moves it later. Returns expirationDate, currentExpirationDate, expirationChangeDays (negative = shorter) and paymentRequired=false; show the customer both dates. Use get_plan_resources first to see available resource IDs for the target plan. Requires services:read when called with an API key.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "orderNo": "<orderNo>",
      "plan": "<plan>",
      "resources": "<resources>"
    },
    "name": "calculate_plan_change"
  }
}

Input Schema

NameRequiredDescriptionDefault
planYesPlan ID from get_plan_options
orderNoYesTenant-owned service order number: 1-64 ASCII letters, digits or hyphens, e.g. VP12345 or VP12345-1
resourcesYesArray of numeric resource value IDs — one per resource type (RAM, SSD, IP, etc.). Get IDs from get_plan_resources response: each resource type has 'values' array, pick one value's 'id' per type. A type left out keeps its current value; an id the target plan does not offer is refused with 422 invalidResources.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.3.16

TDQS

A4.2/5.0
Behavior4/5

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

The annotations already declare readOnlyHint, idempotentHint and destructiveHint=false, so the description does not need to repeat that this is a safe read. The description adds value beyond the annotations: it states that no payment is taken, explains the conversion logic that determines the expiry shift, names the returned fields, and notes that services:read is required when an API key is used.

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?

The description is front-loaded with the preview caveat and the counter-intuitive expiry direction, which are the key facts. Every sentence carries information, although the returned-field list and the auth note make it slightly dense.

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

Completeness5/5

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

The tool is a simple preview with three fully documented parameters and a clear set of return fields; there is no output schema, and the description enumerates the returned values itself. An agent has everything needed to call this tool and interpret the result.

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 three parameters thoroughly, including the per-type resource ID rules and the 422 invalidResources refusal. The description adds little parameter meaning beyond the schema, apart from pointing to get_plan_resources, which the schema also does; the baseline of 3 therefore applies.

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 first sentence names a specific verb and resource: 'Preview a plan change.' The next sentence explains the pricing mechanics, contrasting an upgrade (which 'moves the expiry EARLIER') with a downgrade. That is enough for an agent to tell this tool apart from a sibling such as change_plan without opening a schema.

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

Usage Guidelines4/5

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

The description gives clear situational context: payment is not taken and the result is a preview. It also names a prerequisite: 'Use get_plan_resources first to see available resource IDs.' The one gap is that it never explicitly states when to call the sibling change_plan instead, although the word 'preview' implies that distinction.

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

Deploy Server

Other Tools