How AI is applied across API Evangelist and APIs.io. Read my AI disclosure →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

Datadog Queries API

The Queries API from Datadog — 7 operation(s) for queries.

Datadog Queries API is one of 290 APIs that Datadog publishes on the APIs.io network, described by a machine-readable OpenAPI specification.

This API exposes 4 JSON Schema definitions.

Tagged areas include Query. The published artifact set on APIs.io includes an OpenAPI specification, API documentation, authentication docs, an API reference, and 4 JSON Schemas.

This API exposes 12 operations across 7 paths, and defines 73 schemas. It is described by OpenAPI 3.0.0, at version 1.0.

Requests are made against 3 base URLs: https://{subdomain}.{site}, {protocol}://{name}, https://{subdomain}.{site}.

12 operations 7 paths 73 schemas 2 DELETE5 GET1 PATCH4 POST

Metadata

The identity and technical contract details declared by the specification.

Specification
OpenAPI 3.0.0
API Version
1.0
Base URL
https://api.datadoghq.com
Authentication
OAuth 2.0, API Key, API Key, HTTP Bearer
Resource Areas
1

Authentication & Security 4

Datadog Queries API declares 4 security schemes for authenticating requests. It supports OAuth 2.0 (AuthZ) using the authorizationCode flow, exposing 68 scopes. An API key is passed in the header as DD-API-KEY (apiKeyAuth). An API key is passed in the header as DD-APPLICATION-KEY (appKeyAuth). It accepts HTTP bearer tokens (bearerAuth). By default, every request must be authenticated.

  • AuthZ — This API uses OAuth 2 with the implicit grant flow.
  • apiKeyAuth — Your Datadog API Key.
  • appKeyAuth — Your Datadog APP Key.

Paths & Operations 12

Across 7 paths, the API surfaces 12 operations — 2 DELETE, 5 GET, 1 PATCH, 4 POST. Each is listed below with its method, path, parameters, and response codes.

Queries 12
GET
/api/v2/logs/config/restriction_queries
Datadog List Restriction Queries
ListRestrictionQueries 2 params → 200403429
POST
/api/v2/logs/config/restriction_queries
Datadog Create a Restriction Query
CreateRestrictionQuery body → 200400403429
GET
/api/v2/logs/config/restriction_queries/role/{role_id}
Datadog Get Restriction Query for a Given Role
GetRoleRestrictionQuery 1 param → 200400403429
GET
/api/v2/logs/config/restriction_queries/user/{user_id}
Datadog Get All Restriction Queries for a Given User
ListUserRestrictionQueries 1 param → 200400403429
DELETE
/api/v2/logs/config/restriction_queries/{restriction_query_id}
Datadog Delete a Restriction Query
DeleteRestrictionQuery 1 param → 204400403404429
GET
/api/v2/logs/config/restriction_queries/{restriction_query_id}
Datadog Get a Restriction Query
GetRestrictionQuery 1 param → 200400403404429
PATCH
/api/v2/logs/config/restriction_queries/{restriction_query_id}
Datadog Update a Restriction Query
UpdateRestrictionQuery 1 param body → 200400403404429
DELETE
/api/v2/logs/config/restriction_queries/{restriction_query_id}/roles
Datadog Revoke Role from a Restriction Query
RemoveRoleFromRestrictionQuery 1 param body → 204400403404429
GET
/api/v2/logs/config/restriction_queries/{restriction_query_id}/roles
Datadog List Roles for a Restriction Query
ListRestrictionQueryRoles 3 params → 200400403404429
POST
/api/v2/logs/config/restriction_queries/{restriction_query_id}/roles
Datadog Grant Role to a Restriction Query
AddRoleToRestrictionQuery 1 param body → 204400403404429
POST
/api/v2/query/scalar
Datadog Query Scalar Data Across Multiple Products
QueryScalarData body → 200400401403429
POST
/api/v2/query/timeseries
Datadog Query Timeseries Data Across Multiple Products
QueryTimeseriesData body → 200400401403429

Schemas 73

The contract defines 73 schemas that model the data the API accepts and returns. The most detailed are EventsTimeseriesQuery (6 properties), EventsScalarQuery (6 properties), TimeseriesFormulaRequestAttributes (5 properties), Unit (5 properties). Each schema is shown below with its type and property counts.

RestrictionQueryWithoutRelationships
object
Restriction query object returned by the API.
3 properties
Unit
object
Object containing the metric unit family, scale factor, name, and short name.
5 properties
ScalarMeta
object
Metadata for the resulting numerical values.
1 property
RestrictionQueryRole
object
Partial role object.
3 properties
RestrictionQueryAttributes
object
Attributes of the restriction query.
3 properties
ScalarFormulaRequestType
string
The type of the resource. The value should always be scalarrequest.
EventsQueryGroupBys
array
The list of facets on which to split results.
RestrictionQueryResponseIncludedItem
An object related to a restriction query.
RestrictionQueryWithRelationshipsResponse
object
Response containing information about a single restriction query.
2 properties
ScalarColumnTypeNumber
string
The type of column present for numbers.
TimeseriesFormulaQueryRequest
object
A request wrapper around a single timeseries query to be executed.
1 property 1 required
EventsCompute
object
The instructions for what to compute for this query.
3 properties 1 required
TimeseriesFormulaResponseType
string
The type of the resource. The value should always be timeseriesresponse.
EventsGroupBySort
object
The dimension by which to sort a query's results.
4 properties 1 required
ScalarColumnTypeGroup
string
The type of column present for groups.
GroupScalarColumn
object
A column containing the tag keys and values in a group.
3 properties
MetricsAggregator
string
The type of aggregation that can be performed on metrics-based queries.
MetricsScalarQuery
object
An individual scalar metrics query.
4 properties 3 required
TimeseriesFormulaRequestAttributes
object
The object describing a timeseries formula request.
5 properties 3 required
EventsAggregation
string
The type of aggregation that can be performed on events-based queries.
RestrictionQueryCreateData
object
Data related to the creation of a restriction query.
2 properties
QueryFormula
object
A formula for calculation based on one or more queries.
2 properties 1 required
TimeseriesResponseSeriesList
array
Array of response series. The index here corresponds to the index in the formulas or queries array from the request.
EventsSortType
string
The type of sort to use on the calculated value.
ScalarFormulaRequest
object
A single scalar query to be executed.
2 properties 2 required
RestrictionQueryCreatePayload
object
Create a restriction query.
1 property
ScalarFormulaQueryRequest
object
A wrapper request around one scalar query to be executed.
1 property 1 required
RelationshipToRole
object
Relationship to role.
1 property
EventsDataSource
string
A data source that is powered by the Events Platform.
ScalarResponse
object
A message containing the response to a scalar query.
2 properties
TimeseriesQuery
An individual timeseries query to one of the basic Datadog data sources.
TimeseriesResponseValuesList
array
Array of value-arrays. The index here corresponds to the index in the formulas or queries array from the request.
ScalarFormulaResponseAtrributes
object
The object describing a scalar response.
1 property
RestrictionQueryWithRelationships
object
Restriction query object returned by the API.
4 properties
ScalarFormulaRequestQueries
array
List of queries to be run and used as inputs to the formulas.
RestrictionQueryUpdateData
object
Data related to the update of a restriction query.
2 properties
RestrictionQueryUpdateAttributes
object
Attributes of the edited restriction query.
1 property
MetricsDataSource
string
A data source that is powered by the Metrics platform.
EventsTimeseriesQuery
object
An individual timeseries events query.
6 properties 2 required
QuerySortOrder
string
Direction of sort.
LogsRestrictionQueriesType
string
Restriction query resource type.
ScalarQuery
An individual scalar query to one of the basic Datadog data sources.
ScalarFormulaResponseType
string
The type of the resource. The value should always be scalarresponse.
RestrictionQueryUpdatePayload
object
Update a restriction query.
1 property
EventsSearch
object
Configuration of the search/filter for an events query.
1 property
GroupTags
array
List of tags that apply to a single response value.
RestrictionQueryRoleAttribute
object
Attributes of the role for a restriction query.
1 property
APIErrorResponse
object
API error response.
1 property 1 required
RestrictionQueryCreateAttributes
object
Attributes of the created restriction query.
1 property
TimeseriesFormulaRequest
object
A single timeseries query to be executed.
2 properties 2 required
TimeseriesFormulaRequestQueries
array
List of queries to be run and used as inputs to the formulas.
TimeseriesResponseValues
array
Array of values for an individual formula or query.
ScalarFormulaRequestAttributes
object
The object describing a scalar formula request.
4 properties 3 required
TimeseriesResponseSeries
object
3 properties
RelationshipToRoleData
object
Relationship to role object.
2 properties
EventsScalarQuery
object
An individual scalar events query.
6 properties 2 required
TimeseriesResponseAttributes
object
The object describing a timeseries response.
3 properties
EventsGroupBy
object
A dimension on which to split a query's results.
3 properties 1 required
TimeseriesResponse
object
A message containing the response to a timeseries query.
2 properties
TimeseriesResponseTimes
array
Array of times, 1-1 match with individual values arrays.
RestrictionQueryWithoutRelationshipsResponse
object
Response containing information about a single restriction query.
1 property
TimeseriesFormulaQueryResponse
object
A message containing one response to a timeseries query made with timeseries formula query request.
2 properties
RelationshipToRoles
object
Relationship to roles.
1 property
MetricsTimeseriesQuery
object
An individual timeseries metrics query.
3 properties 2 required
RestrictionQueryListResponse
object
Response containing information about multiple restriction queries.
1 property
RestrictionQueryRolesResponse
object
Response containing information about roles attached to a restriction query.
1 property
ScalarFormulaQueryResponse
object
A message containing one or more responses to scalar queries.
2 properties
RestrictionQueryRelationships
object
Relationships of the restriction query object.
1 property
ScalarColumn
A single column in a scalar query response.
DataScalarColumn
object
A column containing the numerical results for a formula or query.
4 properties
TimeseriesFormulaRequestType
string
The type of the resource. The value should always be timeseriesrequest.
RolesType
string
Roles type.
FormulaLimit
object
Message for specifying limits to the number of values returned by a query. This limit is only for scalar queries and has no effect on timeseries queries.
2 properties

Specification

The full machine-readable OpenAPI contract behind this narrative.

Source

datadog-queries-api-openapi.yml Raw ↑

Other APIs Datadog publishes across the network.

Datadog Dashboards API
Datadog Synthetics API
Datadog Service Level Objectives API
Datadog Security Monitoring API
Datadog Service Definition API
Datadog Software Catalog API
Datadog Users API
Datadog Roles API
Datadog Key Management API
Datadog Organizations API
Datadog Downtimes API
Datadog RUM API
Where this information came from

This is an independent, third-party profile of Datadog Queries API, published by API Evangelist. We do not operate, host, resell, or support these APIs, and we are not affiliated with or endorsed by the company unless stated above. Everything here is built from publicly available information — the company's own site, developer portal, documentation, public repositories, and the specifications it publishes for public use. Nothing is obtained by breaching a system, defeating an access control, or using credentials.

The Kin Score and Agent Readiness rating are independently calculated assessments of a company's public API artifacts, scored against a published rubric. They are not certifications, endorsements, security assessments, or audits.

Corrections, re-scores, and removal are free — no partnership or purchase required, and you do not need to justify the request. A removed company is recorded as unrated, never scored zero for having asked. Acknowledgement within one business day; removal within two.

info@apievangelist.com · Read the full data-sourcing policy →
On a security or compliance team? Put security in the subject line and you will get a person, not a form — we will tell you exactly which public URLs this profile was built from.