{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/api-evangelist/datadog/refs/heads/main/json-schema/datadog-metrics-metric-query-definition-schema.json", "title": "MetricQueryDefinition", "description": "A metric query definition referencing a Datadog metrics query expression", "type": "object", "properties": { "name": { "type": "string", "description": "A unique name used to reference this query in formula expressions", "example": "Example Monitor" }, "data_source": { "type": "string", "description": "The data source for the query", "enum": [ "metrics", "cloud_cost" ], "example": "metrics" }, "query": { "type": "string", "description": "The Datadog metrics query string (e.g., avg:system.cpu.user{*} by {host})", "example": "avg:system.cpu.user{*}" } }, "required": [ "name", "data_source", "query" ] }