Skip to main content
Glama

query_prometheus

Read-only

Execute a PromQL instant query for the cluster. Returns current values as a vector. The platform metrics store answers first and needs no connected Prometheus: it holds the Ankra agent's ankra_* series (labels node; namespace; namespace, workload, kind), e.g. sum by (node) (ankra_node_cpu_usage_cores), sum by (node) (ankra_node_memory_working_set_bytes), ankra_node_cpu_capacity_cores, ankra_node_ready, sum by (namespace) (ankra_namespace_pod_restarts), ankra_namespace_pod_restarts_total, ankra_workload_pod_restarts, ankra_namespace_cpu_usage_cores, ankra_namespace_memory_working_set_bytes. cAdvisor and kube-state-metrics names (container_*, kube_*) answer only from a Prometheus connected in Cluster Settings > Metrics. For a trend or anything over a window use query_prometheus_range.

Input Schema

NameRequiredDescriptionDefault
queryYesPromQL query string (max 2000 chars).
cluster_idYesAnkra cluster id (UUID) the call targets. Discover ids with list_clusters.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior4/5

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

Annotations only declare readOnlyHint=true, so the description carries the rest and does disclose meaningful behavior: which series the built-in platform store answers (ankra_* with their label sets) without any connected Prometheus, and that container_*/kube_* names require a Prometheus connected in Cluster Settings > Metrics. That source-dependency caveat is genuinely useful and not derivable from structured fields. It stops short of covering auth or rate limits, so not a 5.

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 core purpose and routing are front-loaded in the first and last sentences, and each sentence carries information. The middle enumeration of ankra_* series is long and somewhat list-heavy, which costs a little crispness, but it is load-bearing content rather than padding.

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?

For a two-parameter read-only tool with no output schema, the description covers return shape ('current values as a vector'), available data sources, label conventions, and the range-query alternative. An agent has everything needed to call it correctly.

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

Parameters4/5

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

Schema coverage is 100%, so the 3 baseline applies, but the description goes further by supplying concrete example PromQL expressions (sum by (node) (...), ankra_node_ready, etc.) that directly demonstrate how to build the required `query` parameter. It adds nothing about `cluster_id` beyond what the schema already says.

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?

States a specific verb and resource ('Execute a PromQL instant query for the cluster') and explicitly frames the result type ('Returns current values as a vector'). It also names and routes away from the sibling query_prometheus_range, so the agent can distinguish the two without opening either schema.

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

Usage Guidelines5/5

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

Gives explicit when-to-use (instant value, no window), explicit when-not ('For a trend or anything over a window use query_prometheus_range'), and the deciding condition for each. It also states which data source answers which metric name pattern, which is the practical selection guidance an agent needs.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources