get_metrics
Query Datadog metrics with custom filters, aggregations, and time ranges to monitor system performance and analyze data trends.
Instructions
Execute metric queries on Datadog. Specify the metric name and optional filters/aggregations to build and execute the query.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| metric_name | Yes | The metric name to query (e.g., 'aws.apigateway.count', 'system.cpu.user', 'trace.servlet.request.hits') | |
| time_range | No | Time range to look back | 1h |
| aggregation | No | Metric aggregation method | avg |
| filters | No | Filters to apply to the metric query (e.g., {'service': 'web', 'env': 'prod', 'region': 'us-east-1'}) | |
| aggregation_by | No | Fields to group/aggregate the metric by (e.g., ['service'], ['region', 'env'], ['aws_account']). Use get_metric_fields tool to see available fields. | |
| format | No | Output format | table |