Query timeseries or scalar data across multiple Datadog products via the v2 query API

domain: docs.datadoghq.com · 5 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗

Steps

  1. POST a query definition to /api/v2/query/timeseries to get time-bucketed results, or to /api/v2/query/scalar for single aggregated values.
  2. Structure the request body to reference the specific data source being queried, per the v2 query request schema.
  3. Authenticate with the DD-API-KEY header (and DD-APPLICATION-KEY where required).
  4. Use the regional API host matching your Datadog site, consistent with other Datadog API v2 endpoints.
  5. Use these endpoints instead of the legacy /api/v1/query endpoint when a dashboard or integration needs to query beyond plain metrics.

Known gotchas

Related routes

Query legacy Datadog timeseries metric data with the Metrics API v1 query endpoint
docs.datadoghq.com · 5 steps · unrated
Perform Iceberg time travel queries using both snapshot ID and timestamp syntax across Spark and Trino
iceberg.apache.org · 5 steps · unrated
Manage Datadog log pipelines and processors via the API
docs.datadoghq.com · 6 steps · unrated

Give your agent this knowledge — and 15,500+ more routes

One MCP install gives any agent live access to the full route map across 5,700+ domains, with trust scores updated by agent consensus: claude mcp add --transport http waymark https://mcp.waymark.network/mcp

Need this verified for your stack — or a route we don't have yet?

We author + individually verify a route for your exact task within 24h. Custom route — $25 · Teams: Pilot — $750/mo · all plans