Skip to main content
Glama
raviraj-ntp

Dynatrace MCP

by raviraj-ntp

Query Metrics

dynatrace_metrics_query

Run bounded DQL timeseries or Environment API v2 metric selector queries to retrieve Dynatrace metric data with filters, grouping, and time windows.

Instructions

Run a DQL timeseries or Environment API v2 metric selector within date bounds.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
byNoDQL by fields, e.g. k8s.pod.name, k8s.namespace.name
toNoEnd: now or ISO-8601
fromNoStart: now-30m or ISO-8601
aroundNoPivot timestamp for a window
filterNoOptional DQL | filter ...
metricYesMetric id, e.g. dt.kubernetes.container.cpu_usage
windowNoHalf-window around pivot, e.g. 2m
endDateNoCalendar end YYYY-MM-DD (UTC day)
startDateNoCalendar start YYYY-MM-DD (UTC day)
connectionNoNamed connection from env (default, optional stage/prod aliases, or a DYNATRACE_CONNECTIONS key)
useClassicApiNoIf true, GET /api/v2/metrics/query
allowLongRangeNoAllow ranges longer than the default cap

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden, but it discloses almost nothing beyond the one-line purpose. It does not mention the default range cap that allowLongRange overrides, the switch to the classic GET endpoint that useClassicApi triggers, or any auth/connection requirements.

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 front-loaded sentence with zero filler, which is efficient. It is arguably terse given 12 parameters, but no sentence is wasted.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 12-parameter, no-annotation, no-output-schema tool, the description is too thin: it omits the DQL-vs-classic-API selection logic, connection resolution, and range-cap behavior that an agent needs to call it correctly.

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 every one of the 12 parameters is already documented in the schema, which sets the baseline at 3. The description adds only the generic 'within date bounds' framing and no extra meaning for by/filter/window/connection/useClassicApi semantics.

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 gives a specific verb ('Run') and a concrete resource ('DQL timeseries or Environment API v2 metric selector') with a scoping clause ('within date bounds'). It is clear what the tool does, but it never distinguishes itself from the sibling dynatrace_execute_dql or indicates the metric-specific vs generic-DQL boundary.

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 explicit when-to-use guidance, no exclusions, and no reference to alternatives such as dynatrace_execute_dql or dynatrace_verify_dql. Usage is only implied by the metric-selector phrasing.

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