Skip to main content
Glama

query_metric

Read-onlyIdempotent

Query Google Cloud Monitoring metric time series with custom filters, time windows, and aggregation to analyze resource performance and troubleshoot incidents.

Instructions

Query a Cloud Monitoring metric time series.

Args: metric_type: Metric type, e.g. 'compute.googleapis.com/instance/cpu/utilization'. resource_filter: Optional extra filter, e.g. 'resource.labels.instance_id="123"'. window: How far back to query, e.g. '1h', '6h', '1d'. Default '1h'. aligner: Aggregation across the alignment period: MEAN, MAX, MIN, SUM, COUNT, RATE, PERCENTILE_99. Default MEAN. alignment_period: Bucket size for aggregation, e.g. '1m', '5m'. Default '5m'. limit: Maximum number of time series to return. environment: Which configured GCP environment to query, e.g. 'staging' or 'production'. Omit to use the default environment.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo
windowNo1h
alignerNoMEAN
environmentNo
metric_typeYes
resource_filterNo
alignment_periodNo5m

Schema Changelog

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

  1. First observedv0.4.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and idempotentHint=true, so the safety profile is covered. The description adds useful behavioral context: default environment handling, default window/alignment, and aligner semantics. It doesn't mention pagination or output shape, but those are not critical for safe invocation.

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 structure is a single purpose sentence followed by a tight Args block. Each line provides format, default, or allowed values without filler. The length is justified by the need to document seven parameters.

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

Completeness4/5

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

All required inputs and defaults are specified, and the annotations cover safety, so the tool can be called correctly. The only gap is that there is no output schema and the description doesn't describe the shape of the returned time series or how multiple series are returned, but this is a minor omission for a read-only query tool.

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 carries the full burden, and it succeeds. Every parameter is explained with concrete examples or valid values: metric_type, resource_filter, window, aligner options, alignment_period, limit, and environment. This fully compensates for the empty schema descriptions.

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 opens with a specific verb and resource: 'Query a Cloud Monitoring metric time series.' This clearly distinguishes the tool from siblings such as query_logs and list_alert_policies, and the metric_type examples make the target concrete.

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?

The parameter docs explain how to configure the query but never state when to use query_metric instead of sibling tools like query_logs or list_cost_recommendations. Usage is implied by the purpose statement and parameter details, but there is no explicit when-to-use or when-not-to-use guidance.

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/deBilla/platform-mcp'

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