Skip to main content
Glama

get_aggregate_metrics

Aggregate call count, total tokens, and average latency across model calls with optional filters for date range, project, and environment.

Instructions

Get aggregate metrics (call count, total tokens, average latency) across model calls with optional filters.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
toNoFilter calls up to this ISO date
fromNoFilter calls from this ISO date onwards
projectNoFilter by project
environmentNoFilter by environment (dev, staging, prod)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations provided, the description carries the full behavioral burden. The verb 'Get' implies a read-only, non-mutating operation, and 'aggregate metrics' suggests a summarized response rather than raw calls, but there is no explicit disclosure of permissions, rate limits, or behavior when no filters are supplied. This is minimally adequate for a read-only aggregation tool.

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 description is a single, front-loaded sentence that states the operation, the metrics returned, and the filtering scope without any wasted words. It is appropriately sized for a simple aggregation tool.

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?

Given low complexity (four optional filter parameters, no output schema, no annotations), the description provides the essential information: what is computed and that filtering is optional. It omits default behavior when filters are absent and does not describe the response shape, but the lack of an output schema means return values need not be explained in detail.

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 description coverage is 100%, so the schema already fully documents all four optional filter parameters (to, from, project, environment). The description adds only a generic reference to 'optional filters' and does not provide additional parameter semantics beyond what the schema provides, establishing the baseline of 3.

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 states a specific verb (Get), resource (aggregate metrics), and enumerates the metrics returned (call count, total tokens, average latency). It clearly distinguishes itself from siblings like search_model_calls and log_model_call through the aggregating nature, but does not explicitly name or contrast those alternatives.

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 mentions optional filters but gives no guidance on when to use this tool versus alternatives such as search_model_calls or get_session_calls. There are no when-to-use or when-not-to-use conditions, leaving the agent to infer context from the tool name alone.

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