Skip to main content
Glama
ZSvirt

zsvirt-mcp-server

Official
by ZSvirt

get_metric_summary

Get aggregated TopN monitoring metrics (e.g., CPU usage) grouped by resource label, with optional threshold, time range, and period filters for identifying top resource consumers.

Instructions

获取监控指标的聚合 TopN(按 label_key 分组)

Args: namespace: 命名空间,如 "ZStack/VM", "ZStack/Host" metric_name: 指标名称,如 "CPUOccupiedByVm" label_key: 标签键,如 "VMUuid", "HostUuid" metric_names: 可选,多指标合并(如 in/out) start_time: 开始时间(ISO 或秒级时间戳) end_time: 结束时间(ISO 或秒级时间戳) period: 采样周期(秒),默认 60 aggregate: 单指标聚合方式,可选 "max"|"avg"|"sum"|"min" combine: 多指标合并方式,可选 "sum"|"avg"|"max"|"min" threshold_op: 阈值比较符,如 >,>=,<,<=,==,!= threshold_value: 阈值数值 top_n: 返回条数,默认 10 resolve_resource: 可选 "vm" 或 "host",用于解析名称

Returns: 聚合后的 TopN 列表

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
top_nNo
periodNo
combineNosum
end_timeNo
aggregateNomax
label_keyYes
namespaceYes
start_timeNo
metric_nameYes
metric_namesNo
threshold_opNo
threshold_valueNo
resolve_resourceNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv0.1.6

TDQS

B3.3/5.0
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states that it retrieves aggregated TopN values, but does not say whether the call is read-only, what happens when start_time/end_time are omitted, whether threshold filtering is applied before or after aggregation, or how pagination/limits behave.

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 structure is compact and effective: a precise summary line, a well-organized Args list, and a short Returns line. Every entry earns its place, and the parameter list is scannable. It loses one point because the Returns section is extremely terse, though an output schema exists to fill that gap.

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 the tool's complexity (13 parameters, no annotations, 0% schema coverage), the description covers parameter semantics well but leaves critical contextual gaps: when to use it versus sibling tools, whether time ranges are required, and how the TopN grouping behaves. It is a usable but incomplete definition.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must compensate. It does so thoroughly: every one of the 13 parameters gets context, including concrete examples for namespace and metric_name, allowed values for aggregate and combine, format guidance for time parameters, and defaults for period and top_n. This is exactly the kind of compensation needed.

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 one-line summary states a specific verb and resource: fetch aggregated TopN metric values grouped by a label_key. It is clear about the operation, but it does not explicitly differentiate itself from siblings like get_metric_data or search_metric; it relies on the phrase 'aggregated TopN' to imply the distinction.

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 gives no guidance on when to prefer this tool over alternatives such as get_metric_data or search_metric. It lists parameters and return type, but never states the conditions, prerequisites, or scenarios for which this tool is the right choice.

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

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/ZSvirt/zsvirt-mcp-server'

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