Skip to main content
Glama

traffic_stats

Read-only

Fetch a per-service traffic snapshot showing requests, latency, rate, and sessions from Traefik, HAProxy, or Caddy. Use to monitor proxy performance and capacity.

Instructions

[READ] Per-service traffic snapshot: requests, latency/rate/sessions where the platform exposes it (traefik /metrics, haproxy stats; caddy returns the support matrix's teaching note).

Args: target: Proxy target name from config; omit for the default.

Returns an envelope: {"services": [...], "returned": N, "limit": L, "truncated": bool, "total": T}. When "truncated" is true this proxy serves more services than were returned.

Input Schema

NameRequiredDescriptionDefault
targetNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.0

TDQS

A3.6/5.0
Behavior4/5

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

Annotations only declare readOnlyHint=true; the description goes further by disclosing which backends actually expose metrics (traefik /metrics, haproxy stats) and that caddy returns a 'teaching note' instead — valuable expectation-setting. It also explains the truncation semantics of the envelope, though it omits auth/permission requirements. Strong added value beyond the annotation.

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?

Front-loaded with a bracketed read marker and the core purpose, followed by compact Args/Returns sections. A couple of parenthetical asides (e.g. the caddy note) could be tightened, but the structure is readable and mostly earns its length.

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 no output schema, the description compensates by documenting the return envelope fields (services, returned, limit, truncated, total) and the truncation meaning. Combined with the backend coverage caveat, an agent has enough to invoke and interpret it correctly; only cross-tool usage context is thin.

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 0% for the single optional 'target' param, so the description carries the load. It explains that the value comes from the config and that omitting it selects the default, which meaningfully extends the bare string|null schema.

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 description names a specific verb+resource ('Per-service traffic snapshot') and enumerates the metrics returned (requests, latency, rate, sessions), which clearly separates it from config-oriented siblings like list_services and service_detail. It stops short of explicitly naming a sibling it is not, so it lands at 4 rather than 5.

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?

There is no guidance on when to use this tool versus the many related siblings (error_rate_rca, backend_health_rca, error_counters, proxy_overview). The only usage note is about omitting 'target' for the default, which is a parameter detail, not a use-case routing rule.

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