Skip to main content
Glama

subnet_calculate

subnet_calculate
Read-only

Calculate IPv4 or IPv6 subnet metrics—network address, netmask, wildcard, and usable host range—from a CIDR input to plan network addressing.

Instructions

Calculate IPv4 or IPv6 subnet metrics (network, netmask, wildcard, usable range).

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": {
      "cidr": "<cidr>"
    },
    "name": "subnet_calculate"
  }
}

Input Schema

NameRequiredDescriptionDefault
cidrYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false, and openWorldHint=false, so the safety profile is covered structurally. The description adds only the set of computed metrics; it says nothing about behavior on malformed input or out-of-range prefixes, which is the remaining behavioral question for a calculator. Note that idempotentHint=false is unusual for a pure computation, but the description makes no idempotency claim, so this is not a contradiction.

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?

A single front-loaded sentence with no filler, and the enumerated outputs are parenthetical rather than padding. It is efficient, though so terse that the accepted input format never appears.

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 intrinsically simple: one string input, one computed result, and an output schema that documents the return values. Given that the safety traits are supplied by annotations, the description covers everything an agent needs to call it correctly, with input-format detail being the only minor omission.

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 coverage is 0% and the single parameter is documented only as a string titled 'Cidr'. The description partially compensates by stating both IPv4 and IPv6 are accepted, but it does not show the expected form (address plus prefix length, e.g. 192.168.1.0/24) or what happens with a bare address.

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 pairs a specific verb ('Calculate') with a specific resource ('IPv4 or IPv6 subnet metrics') and enumerates the returned quantities (network, netmask, wildcard, usable range). No sibling tool in the catalog performs subnet math, so there is no ambiguity to resolve.

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

Usage Guidelines3/5

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

Usage is only implied: an agent can infer this is the tool for deriving subnet values from a CIDR block. There is no explicit statement of when to prefer it, no note that it is a pure, side-effect-free computation, and no guidance about preconditions such as a well-formed input.

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