Skip to main content
Glama
mcp-prometheus

mcp-prometheus

by AmeesAnsari

query_range

Read-onlyIdempotent

Evaluate PromQL over a time window ending now to retrieve per-series min/max/avg/last summaries and a downsampled timeline for trend analysis.

Instructions

Evaluate PromQL over a time window ending now: per-series min/max/avg/last plus a downsampled timeline.

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": {
      "promql": "<promql>"
    },
    "name": "query_range"
  }
}

Input Schema

NameRequiredDescriptionDefault
promqlYesPromQL expression to evaluate over time.
minutesNoWindow length, ending now (max 7 days).
step_secondsNoResolution. 0 picks one automatically.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, openWorldHint and destructiveHint=false, so the safety profile is fully covered. The description adds the output semantics (aggregations per series plus a downsampled timeline), but since a full output schema exists that information is largely redundant, and nothing is said about cost, rate limits, or truncation of long series sets.

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 dense, front-loaded sentence with no filler; the verb, scope, and return shape all arrive immediately. It is perhaps compressed to the point of obscuring the instant-vs-range distinction, but nothing is wasted.

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?

With rich annotations, 100% parameter coverage, and an output schema, the definition carries only the burden of stating scope and return shape, which it does. The one meaningful gap is that it does not position itself against the 'query' sibling for an agent choosing between point and range evaluation.

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 100%: promql, minutes (1-10080, default 60) and step_seconds (0 = auto) are all documented in-schema, so baseline 3 applies. 'ending now' aligns with the window semantics already stated for 'minutes' but adds no new syntax, format, or edge-case meaning.

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?

States a specific verb ('Evaluate') and resource ('PromQL over a time window ending now') and even previews the reduction output (per-series min/max/avg/last plus a downsampled timeline). An agent can tell this is range/over-time evaluation rather than a point-in-time query, though it never names the sibling 'query' to make the contrast explicit.

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?

'over a time window ending now' implies the range-query use case and the schema's 'minutes' default of 60 reinforces it, but there is no explicit when-to-use statement and no mention of when to prefer the sibling 'query' or 'describe_metric' instead. Guidance is inferable rather than stated.

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