Skip to main content
Glama

queryPointInTimeMetrics

Execute point-in-time queries for one or more engineering metrics.

    Returns current metric values for specified time periods, with support for batch queries
    and optional period-over-period comparisons. Time range (startTime/endTime) cannot exceed 6 months (180 days).

    PREREQUISITES - Follow this workflow:
    1. Discover all available metrics ONCE: Call listMetricDefinitions (view='basic') - cache this response
    2. Get metric query metadata ONCE per metric: Call listMetricDefinitions (view='full', key=METRIC_KEY)
       - supportedAggregations: Valid aggregation methods
       - orderByAttribute: Attribute path for sorting by metric values
       - groupByOptions[].key: Valid groupBy keys (use exact values, do NOT guess)
       - filterOptions[].key: Valid filter keys (use exact values, do NOT guess)
       Cache the full view response for each metric. Reuse the metadata from cached responses for subsequent queries on the same metric.
    3. Construct query: Use the query metadata from the full view responses in step 2 to build valid point-in-time requests

    IMPORTANT: Cache only results from listMetricDefinitions. Do NOT cache point-in-time query results - always execute fresh queries for current data.
    Only refresh cached listMetricDefinitions responses if no longer in your context window or explicitly requested.
    Do NOT guess attribute names - always use exact values from listMetricDefinitions responses.

    Response includes:
    - Lightweight metadata: Column definitions optimized for programmatic use
    - Row data: Actual metric values and dimensional data
    - No heavy schemas: Source definitions excluded (get from listMetricDefinitions instead)

    Error responses:
    - 400: Invalid metric names, date range, validation errors, or unsupported metric combinations
    - 403: Feature not enabled (contact help@cortex.io)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitYesMaximum number of results to return
contextYes Explain why you're invoking this tool now and how its output will be used. Then state how this call supports your *overall objective* and fits into your broader plan across all tool calls (e.g., why this tool vs. others, and what step it unblocks). Never share any personal details or sensitive information.
endTimeYesEnd time for the query period
filtersYesFilters to apply to the data
groupByYesFields to group results by
metricsYesList of metrics to query with their aggregation functions
orderByYesSort order for results
nextPageNoPagination token for next page of results
startTimeYesStart time for the query period
comparisonNo
nestedGroupByNoFields to group nested results by
nestedMetricsNoOptional nested metrics for advanced queries
timeAttributeNoTime attribute to use for queries
nestedTimeAttributeNoTime attribute for nested queries

TDQS

A4.6/5.0
Behavior5/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It discloses the 6-month (180-day) time range limit, response structure (lightweight metadata, row data, no heavy schemas), error codes (400 and 403), and explicit caching instructions ('Do NOT cache point-in-time query results - always execute fresh queries'). It also clarifies that listMetricDefinitions results, not query results, should be cached. This is thorough and goes well beyond the schema.

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 description is longer than typical but is well-organized into sections: a brief overview, PREREQUISITES with numbered workflow, IMPORTANT caching notes, response summary, and error codes. Each section earns its place given the tool's complexity. It is not bloated with repeated schema info, though it could be trimmed slightly without losing value.

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?

Given the tool's complexity (14 parameters, 8 required, no output schema), the description provides a complete operational picture. It tells the agent exactly how to discover metrics, construct valid queries, handle caching, interpret responses, and anticipate errors. The reference to listMetricDefinitions fills the gap between discovery and execution, making the tool usable without additional context.

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?

The input schema already covers 93% of parameters with descriptions, so the baseline is 3. The description adds crucial context beyond the schema: it explains that metric names, groupBy keys, filter keys, and orderBy attributes must come from listMetricDefinitions full view responses, and that startTime/endTime cannot span more than 180 days. This guidance directly helps construct valid values for metrics, groupBy, filters, and orderBy, which are otherwise only schematically described.

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 clearly states the tool's function: 'Execute point-in-time queries for one or more engineering metrics' and specifies it returns 'current metric values for specified time periods, with support for batch queries and optional period-over-period comparisons.' It also distinguishes itself from sibling tools by referencing listMetricDefinitions as a prerequisite for discovery, making the division of labor explicit.

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

Usage Guidelines4/5

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

The description offers a detailed workflow: call listMetricDefinitions first to discover metrics and cache metadata, then construct queries using exact values from those responses. It explicitly says 'Do NOT guess attribute names' and explains when to refresh cached metadata. However, it does not explicitly name alternative query tools (e.g., getCustomMetricData) or state when not to use this tool versus those alternatives, so it stops short of a 5.

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.

TDQS

C2.7/5.0
Disambiguation2/5

Several tools have overlapping or unclear boundaries, notably getEntityDescriptor and listEntityDescriptors share identical descriptions, and getEntityDetails may be confused with them. This ambiguity could easily lead an agent to select the wrong tool for a catalog lookup.

Naming Consistency3/5

Most tools follow a camelCase getXxx/listXxx pattern, but there are clear exceptions like query_docs and get_more_tools that use snake_case, and the verb set includes get, list, query, and search. The mixed conventions are still readable but not fully consistent.

Tool Count2/5

With 31 tools, the surface feels oversized, especially considering the redundant descriptor tools and the meta-tool get_more_tools. The scope is broad but could benefit from splitting into separate servers for catalog, metrics, and other functions.

Completeness2/5

The tool set is almost entirely read-only (get/list/search/query) with no create, update, or delete operations, despite descriptions mentioning 'manage your service catalog'. This leaves significant lifecycle gaps and prevents full catalog management workflows.

Resources