---
title: Create a notebook
description: Datadog, the leading service for cloud-scale monitoring.
breadcrumbs: Docs > API Reference > Notebooks
---

> For the complete documentation index, see [llms.txt](https://docs.datadoghq.com/llms.txt).

# Create a notebook{% #create-a-notebook %}
Copy pageCopied
{% tab title="v1" %}

| Datadog site      | API endpoint                                        |
| ----------------- | --------------------------------------------------- |
| ap1.datadoghq.com | POST https://api.ap1.datadoghq.com/api/v1/notebooks |
| ap2.datadoghq.com | POST https://api.ap2.datadoghq.com/api/v1/notebooks |
| app.datadoghq.eu  | POST https://api.datadoghq.eu/api/v1/notebooks      |
| app.ddog-gov.com  | POST https://api.ddog-gov.com/api/v1/notebooks      |
| us2.ddog-gov.com  | POST https://api.us2.ddog-gov.com/api/v1/notebooks  |
| uk1.datadoghq.com | POST https://api.uk1.datadoghq.com/api/v1/notebooks |
| app.datadoghq.com | POST https://api.datadoghq.com/api/v1/notebooks     |
| us3.datadoghq.com | POST https://api.us3.datadoghq.com/api/v1/notebooks |
| us5.datadoghq.com | POST https://api.us5.datadoghq.com/api/v1/notebooks |

### Overview

Create a notebook using the specified options. This endpoint requires the `notebooks_write` permission.

### Request

#### Body Data (required)

The JSON description of the notebook you want to create.

{% tab title="Model" %}

| Parent field                              | Field                                     | Type                | Description                                                                                                                                                                                                                                                                                                                           |
| ----------------------------------------- | ----------------------------------------- | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|                                           | data [*required*]                    | object              | The data for a notebook create request.                                                                                                                                                                                                                                                                                               |
| data                                      | attributes [*required*]              | object              | The data attributes of a notebook.                                                                                                                                                                                                                                                                                                    |
| attributes                                | cells [*required*]                   | [object]            | List of cells to display in the notebook.                                                                                                                                                                                                                                                                                             |
| cells                                     | attributes [*required*]              |  <oneOf>       | The attributes of a notebook cell in create cell request. Valid cell types are `markdown`, `timeseries`, `toplist`, `heatmap`, `distribution`, `log_stream`. [More information on each graph visualization type.](https://docs.datadoghq.com/dashboards/widgets.md)                                                                   |
| attributes                                | Object 1                                  | object              | The attributes of a notebook `markdown` cell.                                                                                                                                                                                                                                                                                         |
| Object 1                                  | definition [*required*]              | object              | Text in a notebook is formatted with [Markdown](https://daringfireball.net/projects/markdown/), which enables the use of headings, subheadings, links, images, lists, and code blocks.                                                                                                                                                |
| definition                                | text [*required*]                    | string              | The markdown content.                                                                                                                                                                                                                                                                                                                 |
| definition                                | type [*required*]                    | enum                | Type of the markdown cell. Allowed enum values: `markdown`                                                                                                                                                                                                                                                                            |
| attributes                                | Object 2                                  | object              | The attributes of a notebook `timeseries` cell.                                                                                                                                                                                                                                                                                       |
| Object 2                                  | definition [*required*]              | object              | The timeseries visualization allows you to display the evolution of one or more metrics, log events, or Indexed Spans over time.                                                                                                                                                                                                      |
| definition                                | custom_links                              | [object]            | List of custom links.                                                                                                                                                                                                                                                                                                                 |
| custom_links                              | is_hidden                                 | boolean             | The flag for toggling context menu link visibility.                                                                                                                                                                                                                                                                                   |
| custom_links                              | label                                     | string              | The label for the custom link URL. Keep the label short and descriptive. Use metrics and tags as variables.                                                                                                                                                                                                                           |
| custom_links                              | link                                      | string              | The URL of the custom link. URL must include `http` or `https`. A relative URL must start with `/`.                                                                                                                                                                                                                                   |
| custom_links                              | override_label                            | string              | The label ID that refers to a context menu link. Can be `logs`, `hosts`, `traces`, `profiles`, `processes`, `containers`, or `rum`.                                                                                                                                                                                                   |
| definition                                | description                               | string              | The description of the widget.                                                                                                                                                                                                                                                                                                        |
| definition                                | events                                    | [object]            | **DEPRECATED**: List of widget events. Deprecated - Use `overlay` request type instead.                                                                                                                                                                                                                                               |
| events                                    | q [*required*]                       | string              | Query definition.                                                                                                                                                                                                                                                                                                                     |
| events                                    | tags_execution                            | string              | The execution method for multi-value filters.                                                                                                                                                                                                                                                                                         |
| definition                                | legend_columns                            | [string]            | Columns displayed in the legend.                                                                                                                                                                                                                                                                                                      |
| definition                                | legend_layout                             | enum                | Layout of the legend. Allowed enum values: `auto,horizontal,vertical`                                                                                                                                                                                                                                                                 |
| definition                                | legend_size                               | string              | Available legend sizes for a widget. Should be one of "0", "2", "4", "8", "16", or "auto".                                                                                                                                                                                                                                            |
| definition                                | markers                                   | [object]            | List of markers.                                                                                                                                                                                                                                                                                                                      |
| markers                                   | display_type                              | string              | Combination of:                                                                                                                                                                                                                                                                                                                       |
| markers                                   | label                                     | string              | Label to display over the marker.                                                                                                                                                                                                                                                                                                     |
| markers                                   | time                                      | string              | Timestamp for the widget.                                                                                                                                                                                                                                                                                                             |
| markers                                   | value [*required*]                   | string              | Value to apply. Can be a single value y = 15 or a range of values 0 < y < 10. For Distribution widgets with `display_type` set to `percentile`, this should be a numeric percentile value (for example, "90" for P90).                                                                                                                |
| definition                                | requests [*required*]                | [object]            | List of timeseries widget requests.                                                                                                                                                                                                                                                                                                   |
| requests                                  | apm_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| apm_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| apm_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| apm_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | audit_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| audit_query                               | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| audit_query                               | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| audit_query                               | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| audit_query                               | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| audit_query                               | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | display_type                              | enum                | Type of display to use for the request. Allowed enum values: `area,bars,line,overlay`                                                                                                                                                                                                                                                 |
| requests                                  | event_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| event_query                               | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| event_query                               | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| event_query                               | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | formulas                                  | [object]            | List of formulas that operate on queries.                                                                                                                                                                                                                                                                                             |
| formulas                                  | alias                                     | string              | Expression alias.                                                                                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode                         | enum                | Define a display mode for the table cell. Allowed enum values: `number,bar,trend`                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode_options                 | object              | Cell display mode options for the widget formula. (only if `cell_display_mode` is set to `trend`).                                                                                                                                                                                                                                    |
| cell_display_mode_options                 | trend_type                                | enum                | Trend type for the cell display mode options. Allowed enum values: `area,line,bars`                                                                                                                                                                                                                                                   |
| cell_display_mode_options                 | y_scale                                   | enum                | Y scale for the cell display mode options. Allowed enum values: `shared,independent`                                                                                                                                                                                                                                                  |
| formulas                                  | conditional_formats                       | [object]            | List of conditional formats.                                                                                                                                                                                                                                                                                                          |
| conditional_formats                       | comparator [*required*]              | enum                | Comparator to apply. Allowed enum values: `=,>,>=,<,<=`                                                                                                                                                                                                                                                                               |
| conditional_formats                       | custom_bg_color                           | string              | Color palette to apply to the background, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | custom_fg_color                           | string              | Color palette to apply to the foreground, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | hide_value                                | boolean             | True hides values.                                                                                                                                                                                                                                                                                                                    |
| conditional_formats                       | image_url                                 | string              | Displays an image as the background.                                                                                                                                                                                                                                                                                                  |
| conditional_formats                       | metric                                    | string              | Metric from the request to correlate this conditional format with.                                                                                                                                                                                                                                                                    |
| conditional_formats                       | palette [*required*]                 | enum                | Color palette to apply. Allowed enum values: `blue,custom_bg,custom_image,custom_text,gray_on_white,grey,green,orange,red,red_on_white`                                                                                                                                                                                               |
| conditional_formats                       | timeframe                                 | string              | Defines the displayed timeframe.                                                                                                                                                                                                                                                                                                      |
| conditional_formats                       | value [*required*]                   | double              | Value for the comparator.                                                                                                                                                                                                                                                                                                             |
| formulas                                  | formula [*required*]                 | string              | String expression built from queries, formulas, and functions.                                                                                                                                                                                                                                                                        |
| formulas                                  | limit                                     | object              | Options for limiting results returned.                                                                                                                                                                                                                                                                                                |
| limit                                     | count                                     | int64               | Number of results to return.                                                                                                                                                                                                                                                                                                          |
| limit                                     | order                                     | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| formulas                                  | number_format                             | object              | Number format options for the widget.                                                                                                                                                                                                                                                                                                 |
| number_format                             | unit                                      |  <oneOf>       | Number format unit.                                                                                                                                                                                                                                                                                                                   |
| unit                                      | <type=canonical_unit>                     | object              | Canonical unit.                                                                                                                                                                                                                                                                                                                       |
| unit                                      | <type=custom_unit_label>                  | object              | Custom unit.                                                                                                                                                                                                                                                                                                                          |
| number_format                             | unit_scale                                | object              | The definition of `NumberFormatUnitScale` object.                                                                                                                                                                                                                                                                                     |
| unit_scale                                | type                                      | enum                | The type of unit scale. Allowed enum values: `canonical_unit`                                                                                                                                                                                                                                                                         |
| unit_scale                                | unit_name                                 | string              | The name of the unit.                                                                                                                                                                                                                                                                                                                 |
| formulas                                  | style                                     | object              | Styling options for widget formulas.                                                                                                                                                                                                                                                                                                  |
| style                                     | palette                                   | string              | The color palette used to display the formula. A guide to the available color palettes can be found at [https://docs.datadoghq.com/dashboards/guide/widget_colors](https://docs.datadoghq.com/dashboards/guide/widget_colors.md)                                                                                                      |
| style                                     | palette_index                             | int64               | Index specifying which color to use within the palette.                                                                                                                                                                                                                                                                               |
| requests                                  | log_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| log_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| log_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| log_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | metadata                                  | [object]            | Used to define expression aliases.                                                                                                                                                                                                                                                                                                    |
| metadata                                  | alias_name                                | string              | Expression alias.                                                                                                                                                                                                                                                                                                                     |
| metadata                                  | expression [*required*]              | string              | Expression name.                                                                                                                                                                                                                                                                                                                      |
| requests                                  | network_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| network_query                             | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| network_query                             | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| network_query                             | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | on_right_yaxis                            | boolean             | Whether or not to display a second y-axis on the right.                                                                                                                                                                                                                                                                               |
| requests                                  | process_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| process_query                             | filter_by                                 | [string]            | List of processes.                                                                                                                                                                                                                                                                                                                    |
| process_query                             | limit                                     | int64               | Max number of items in the filter list.                                                                                                                                                                                                                                                                                               |
| process_query                             | metric [*required*]                  | string              | Your chosen metric.                                                                                                                                                                                                                                                                                                                   |
| process_query                             | search_by                                 | string              | Your chosen search term.                                                                                                                                                                                                                                                                                                              |
| requests                                  | profile_metrics_query                     | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| profile_metrics_query                     | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| profile_metrics_query                     | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | q                                         | string              | **DEPRECATED**: Widget query. Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                      |
| requests                                  | queries                                   | [ <oneOf>]     | List of queries that can be returned directly or used in formulas.                                                                                                                                                                                                                                                                    |
| queries                                   | <data_source=metrics>                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| <data_source=metrics>                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=metrics>                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| <data_source=metrics>                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| <data_source=metrics>                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| queries                                   | Object 2                                  | object              | A formula and functions events query.                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | compute [*required*]                 | object              | Compute options.                                                                                                                                                                                                                                                                                                                      |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | int64               | A time interval in milliseconds.                                                                                                                                                                                                                                                                                                      |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| Object 2                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 2                                  | data_source [*required*]             | enum                | Data source for event platform-based queries. Allowed enum values: `logs,spans,network,rum,security_signals,profiles,audit,events,ci_tests,ci_pipelines`                                                                                                                                                                              |
| Object 2                                  | group_by                                  |  <oneOf>       | Group by configuration for a formula and functions events query. Accepts either a list of facet objects or a flat object that specifies a list of facet fields.                                                                                                                                                                       |
| group_by                                  | Object 1                                  | [object]            | List of objects used to group by.                                                                                                                                                                                                                                                                                                     |
| group_by                                  | Object 2                                  | object              | Flat group by configuration using multiple event facet fields.                                                                                                                                                                                                                                                                        |
| Object 2                                  | indexes                                   | [string]            | An array of index names to query in the stream. Omit or use `[]` to query all indexes at once.                                                                                                                                                                                                                                        |
| Object 2                                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| Object 2                                  | search                                    | object              | Search options.                                                                                                                                                                                                                                                                                                                       |
| search                                    | query [*required*]                   | string              | Events search string.                                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | storage                                   | string              | Option for storage location. Feature in Private Beta.                                                                                                                                                                                                                                                                                 |
| queries                                   | Object 3                                  | object              | Process query using formulas and functions.                                                                                                                                                                                                                                                                                           |
| Object 3                                  | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| Object 3                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 3                                  | data_source [*required*]             | enum                | Data sources that rely on the process backend. Allowed enum values: `process,container`                                                                                                                                                                                                                                               |
| Object 3                                  | is_normalized_cpu                         | boolean             | Whether to normalize the CPU percentages.                                                                                                                                                                                                                                                                                             |
| Object 3                                  | limit                                     | int64               | Number of hits to return.                                                                                                                                                                                                                                                                                                             |
| Object 3                                  | metric [*required*]                  | string              | Process metric name.                                                                                                                                                                                                                                                                                                                  |
| Object 3                                  | name [*required*]                    | string              | Name of query for use in formulas.                                                                                                                                                                                                                                                                                                    |
| Object 3                                  | sort                                      | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| Object 3                                  | tag_filters                               | [string]            | An array of tags to filter by.                                                                                                                                                                                                                                                                                                        |
| Object 3                                  | text_filter                               | string              | Text to use as filter.                                                                                                                                                                                                                                                                                                                |
| queries                                   | <data_source=apm_dependency_stats>        | object              | A formula and functions APM dependency stats query.                                                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | data_source [*required*]             | enum                | Data source for APM dependency stats queries. Allowed enum values: `apm_dependency_stats`                                                                                                                                                                                                                                             |
| <data_source=apm_dependency_stats>        | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_dependency_stats>        | is_upstream                               | boolean             | Determines whether stats for upstream or downstream dependencies should be queried.                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | name [*required*]                    | string              | Name of query to use in formulas.                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_dependency_stats>        | operation_name [*required*]          | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | primary_tag_name                          | string              | The name of the second primary tag used within APM; required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog). |
| <data_source=apm_dependency_stats>        | primary_tag_value                         | string              | Filter APM data by the second primary tag. `primary_tag_name` must also be specified.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | resource_name [*required*]           | string              | APM resource.                                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | service [*required*]                 | string              | APM service.                                                                                                                                                                                                                                                                                                                          |
| <data_source=apm_dependency_stats>        | stat [*required*]                    | enum                | APM statistic. Allowed enum values: `avg_duration,avg_root_duration,avg_spans_per_trace,error_rate,pct_exec_time,pct_of_traces,total_traces_count`                                                                                                                                                                                    |
| queries                                   | <data_source=apm_resource_stats>          | object              | **DEPRECATED**: APM resource stats query using formulas and functions. Deprecated - Use `apm_metrics` query type instead.                                                                                                                                                                                                             |
| <data_source=apm_resource_stats>          | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | data_source [*required*]             | enum                | Data source for APM resource stats queries. Allowed enum values: `apm_resource_stats`                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_resource_stats>          | group_by                                  | [string]            | Array of fields to group results by.                                                                                                                                                                                                                                                                                                  |
| <data_source=apm_resource_stats>          | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_resource_stats>          | operation_name                            | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_resource_stats>          | primary_tag_name                          | string              | Name of the second primary tag used within APM. Required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog)      |
| <data_source=apm_resource_stats>          | primary_tag_value                         | string              | Value of the second primary tag by which to filter APM data. `primary_tag_name` must also be specified.                                                                                                                                                                                                                               |
| <data_source=apm_resource_stats>          | resource_name                             | string              | APM resource name.                                                                                                                                                                                                                                                                                                                    |
| <data_source=apm_resource_stats>          | service [*required*]                 | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_resource_stats>          | stat [*required*]                    | enum                | APM resource stat name. Allowed enum values: `errors,error_rate,hits,latency_avg,latency_distribution,latency_max,latency_p50,latency_p75,latency_p90,latency_p95`                                                                                                                                                                    |
| queries                                   | <data_source=apm_metrics>                 | object              | A formula and functions APM metrics query.                                                                                                                                                                                                                                                                                            |
| <data_source=apm_metrics>                 | data_source [*required*]             | enum                | Data source for APM metrics queries. Allowed enum values: `apm_metrics`                                                                                                                                                                                                                                                               |
| <data_source=apm_metrics>                 | group_by                                  | [string]            | Optional fields to group the query results by.                                                                                                                                                                                                                                                                                        |
| <data_source=apm_metrics>                 | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_metrics>                 | operation_mode                            | string              | Optional operation mode to aggregate across operation names.                                                                                                                                                                                                                                                                          |
| <data_source=apm_metrics>                 | operation_name                            | string              | Name of operation on service. If not provided, the primary operation name is used.                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | peer_tags                                 | [string]            | Tags to query for a specific downstream entity (peer.service, peer.db_instance, peer.s3, peer.s3.bucket, etc.).                                                                                                                                                                                                                       |
| <data_source=apm_metrics>                 | query_filter                              | string              | Additional filters for the query using metrics query syntax (e.g., env, primary_tag).                                                                                                                                                                                                                                                 |
| <data_source=apm_metrics>                 | resource_hash                             | string              | The hash of a specific resource to filter by.                                                                                                                                                                                                                                                                                         |
| <data_source=apm_metrics>                 | resource_name                             | string              | The full name of a specific resource to filter by.                                                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | service                                   | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_metrics>                 | span_kind                                 | enum                | Describes the relationship between the span, its parents, and its children in a trace. Allowed enum values: `consumer,server,client,producer,internal`                                                                                                                                                                                |
| <data_source=apm_metrics>                 | stat [*required*]                    | enum                | APM metric stat name. Allowed enum values: `errors,error_rate,errors_per_second,latency_avg,latency_max,latency_p50,latency_p75,latency_p90,latency_p95,latency_p99`                                                                                                                                                                  |
| queries                                   | <data_source=slo>                         | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | additional_query_filters                  | string              | Additional filters applied to the SLO query.                                                                                                                                                                                                                                                                                          |
| <data_source=slo>                         | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=slo>                         | data_source [*required*]             | enum                | Data source for SLO measures queries. Allowed enum values: `slo`                                                                                                                                                                                                                                                                      |
| <data_source=slo>                         | group_mode                                | enum                | Group mode to query measures. Allowed enum values: `overall,components`                                                                                                                                                                                                                                                               |
| <data_source=slo>                         | measure [*required*]                 | enum                | SLO measures queries. Allowed enum values: `good_events,bad_events,good_minutes,bad_minutes,slo_status,error_budget_remaining,burn_rate,error_budget_burndown`                                                                                                                                                                        |
| <data_source=slo>                         | name                                      | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | slo_id [*required*]                  | string              | ID of an SLO to query measures.                                                                                                                                                                                                                                                                                                       |
| <data_source=slo>                         | slo_query_type                            | enum                | Name of the query for use in formulas. Allowed enum values: `metric,monitor,time_slice`                                                                                                                                                                                                                                               |
| queries                                   | <data_source=cloud_cost>                  | object              | A formula and functions Cloud Cost query.                                                                                                                                                                                                                                                                                             |
| <data_source=cloud_cost>                  | aggregator                                | enum                | Aggregator used for the request. Allowed enum values: `avg,last,max,min,sum,percentile`                                                                                                                                                                                                                                               |
| <data_source=cloud_cost>                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | data_source [*required*]             | enum                | Data source for Cloud Cost queries. Allowed enum values: `cloud_cost`                                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=cloud_cost>                  | query [*required*]                   | string              | Query for Cloud Cost data.                                                                                                                                                                                                                                                                                                            |
| queries                                   | <data_source=product_analytics_extended>  | object              | A formula and functions Product Analytics Extended query for advanced analytics features.                                                                                                                                                                                                                                             |
| <data_source=product_analytics_extended>  | audience_filters                          | object              | Product Analytics/RUM audience filters.                                                                                                                                                                                                                                                                                               |
| audience_filters                          | accounts                                  | [object]            |
| audience_filters                          | filter_condition                          | string              | An optional filter condition applied to the audience subquery.                                                                                                                                                                                                                                                                        |
| audience_filters                          | segments                                  | [object]            |
| audience_filters                          | users                                     | [object]            |
| <data_source=product_analytics_extended>  | compute [*required*]                 | object              | Compute configuration for Product Analytics Extended queries.                                                                                                                                                                                                                                                                         |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Fixed-width time bucket interval in milliseconds for time series queries. Mutually exclusive with `rollup`.                                                                                                                                                                                                                           |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| compute                                   | name                                      | string              | Name of the compute for use in formulas.                                                                                                                                                                                                                                                                                              |
| compute                                   | rollup                                    | object              | Calendar-aligned time bucket for time series queries (for example, day, week, or month boundaries). Mutually exclusive with `interval`.                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | data_source [*required*]             | enum                | Data source for Product Analytics Extended queries. Allowed enum values: `product_analytics_extended`                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | indexes                                   | [string]            | Event indexes to query.                                                                                                                                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_extended>  | query [*required*]                   | object              | Base query for Product Analytics.                                                                                                                                                                                                                                                                                                     |
| query                                     | data_source [*required*]             | enum                | Data source for Product Analytics event queries. Allowed enum values: `product_analytics`                                                                                                                                                                                                                                             |
| query                                     | search [*required*]                  | object              | Search configuration for Product Analytics event query.                                                                                                                                                                                                                                                                               |
| queries                                   | <data_source=product_analytics_journey>   | object              | A formula and functions User Journey query for defining funnel, timeseries, and scalar visualizations over journey data.                                                                                                                                                                                                              |
| <data_source=product_analytics_journey>   | compute [*required*]                 | object              | Compute configuration for User Journey formula queries.                                                                                                                                                                                                                                                                               |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Time bucket interval in milliseconds for time series queries.                                                                                                                                                                                                                                                                         |
| compute                                   | metric                                    | enum                | Metric for User Journey formula compute. `__dd.conversion` and `__dd.conversion_rate` accept `count` and `cardinality` as aggregations. `__dd.time_to_convert` accepts `avg`, `median`, `pc75`, `pc95`, `pc98`, `pc99`, `min`, and `max`. Allowed enum values: `__dd.conversion,__dd.conversion_rate,__dd.time_to_convert`            |
| compute                                   | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | data_source [*required*]             | enum                | Data source for user journey funnel queries. Allowed enum values: `product_analytics_journey`                                                                                                                                                                                                                                         |
| <data_source=product_analytics_journey>   | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_journey>   | search [*required*]                  | object              | User journey search configuration.                                                                                                                                                                                                                                                                                                    |
| search                                    | expression [*required*]              | string              | Expression string.                                                                                                                                                                                                                                                                                                                    |
| search                                    | filters                                   | object              | Filters for user journey search.                                                                                                                                                                                                                                                                                                      |
| search                                    | join_keys                                 | object              | Join keys for user journey queries.                                                                                                                                                                                                                                                                                                   |
| search                                    | node_objects [*required*]            | object              | Node objects mapping.                                                                                                                                                                                                                                                                                                                 |
| search                                    | step_aliases                              | object              | Step aliases mapping.                                                                                                                                                                                                                                                                                                                 |
| queries                                   | <data_source=product_analytics_retention> | object              | A formula and functions Retention query for defining timeseries and scalar visualizations.                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | compute [*required*]                 | object              | Compute configuration for retention queries.                                                                                                                                                                                                                                                                                          |
| compute                                   | aggregation [*required*]             |  <oneOf>       | The type of aggregation that can be performed on events-based queries.                                                                                                                                                                                                                                                                |
| compute                                   | metric [*required*]                  | enum                | Metric for retention compute. Allowed enum values: `__dd.retention,__dd.retention_rate`                                                                                                                                                                                                                                               |
| <data_source=product_analytics_retention> | data_source [*required*]             | enum                | Data source for retention queries. Allowed enum values: `product_analytics_retention`                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_retention> | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet to group by.                                                                                                                                                                                                                                                                                                                    |
| group_by                                  | limit                                     | int64               | Maximum number of groups.                                                                                                                                                                                                                                                                                                             |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude missing values.                                                                                                                                                                                                                                                                                                    |
| group_by                                  | sort                                      | object              | Sort configuration for retention group by.                                                                                                                                                                                                                                                                                            |
| group_by                                  | source                                    | string              | Source field.                                                                                                                                                                                                                                                                                                                         |
| group_by                                  | target [*required*]                  | enum                | Target for retention group by. Allowed enum values: `cohort,return_period`                                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_retention> | search [*required*]                  | object              | Search configuration for retention queries.                                                                                                                                                                                                                                                                                           |
| search                                    | cohort_criteria [*required*]         | object              | Cohort criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| search                                    | filters                                   | object              | Filters for retention queries.                                                                                                                                                                                                                                                                                                        |
| search                                    | retention_entity [*required*]        | enum                | Entity to track for retention. Allowed enum values: `@usr.id,@account.id`                                                                                                                                                                                                                                                             |
| search                                    | return_condition [*required*]        | enum                | Condition for counting user return. Allowed enum values: `conversion_on,conversion_on_or_after`                                                                                                                                                                                                                                       |
| search                                    | return_criteria                           | object              | Return criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| requests                                  | response_format                           | enum                | Timeseries, scalar, or event list response. Event list response formats are supported by Geomap widgets. Allowed enum values: `timeseries,scalar,event_list`                                                                                                                                                                          |
| requests                                  | rum_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| rum_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| rum_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| rum_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | security_query                            | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| security_query                            | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| security_query                            | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| security_query                            | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | style                                     | object              | Define request widget style for timeseries widgets.                                                                                                                                                                                                                                                                                   |
| style                                     | has_value_labels                          | boolean             | If true, the value is displayed as a label relative to the data point.                                                                                                                                                                                                                                                                |
| style                                     | line_type                                 | enum                | Type of lines displayed. Allowed enum values: `dashed,dotted,solid`                                                                                                                                                                                                                                                                   |
| style                                     | line_width                                | enum                | Width of line displayed. Allowed enum values: `normal,thick,thin`                                                                                                                                                                                                                                                                     |
| style                                     | order_by                                  | enum                | How to order series in timeseries visualizations.                                                                                                                                                                                                                                                                                     |
| style                                     | palette                                   | string              | Color palette to apply to the widget.                                                                                                                                                                                                                                                                                                 |
| definition                                | right_yaxis                               | object              | Axis controls for the widget.                                                                                                                                                                                                                                                                                                         |
| right_yaxis                               | include_zero                              | boolean             | Set to `true` to include zero.                                                                                                                                                                                                                                                                                                        |
| right_yaxis                               | label                                     | string              | The label of the axis to display on the graph. Only usable on Scatterplot Widgets.                                                                                                                                                                                                                                                    |
| right_yaxis                               | max                                       | string              | Specifies maximum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| right_yaxis                               | min                                       | string              | Specifies minimum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| right_yaxis                               | scale                                     | string              | Specifies the scale type. Possible values are `linear`, `log`, `sqrt`, and `pow##` (for example `pow2` or `pow0.5`).                                                                                                                                                                                                                  |
| definition                                | show_legend                               | boolean             | (screenboard only) Show the legend for this widget.                                                                                                                                                                                                                                                                                   |
| definition                                | time                                      |  <oneOf>       | Time setting for the widget.                                                                                                                                                                                                                                                                                                          |
| time                                      | Object 1                                  | object              | Wrapper for live span                                                                                                                                                                                                                                                                                                                 |
| Object 1                                  | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span                                 | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | <type=live>                               | object              | Used for arbitrary live span times, such as 17 minutes or 6 hours.                                                                                                                                                                                                                                                                    |
| <type=live>                               | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=live>                               | type [*required*]                    | enum                | Type "live" denotes a live span in the new format. Allowed enum values: `live`                                                                                                                                                                                                                                                        |
| <type=live>                               | unit [*required*]                    | enum                | Unit of the time span. Allowed enum values: `minute,hour,day,week,month,year`                                                                                                                                                                                                                                                         |
| <type=live>                               | value [*required*]                   | int64               | Value of the time span.                                                                                                                                                                                                                                                                                                               |
| time                                      | <type=fixed>                              | object              | Used for fixed span times, such as 'March 1 to March 7'.                                                                                                                                                                                                                                                                              |
| <type=fixed>                              | from [*required*]                    | int64               | Start time in milliseconds since epoch.                                                                                                                                                                                                                                                                                               |
| <type=fixed>                              | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=fixed>                              | to [*required*]                      | int64               | End time in milliseconds since epoch.                                                                                                                                                                                                                                                                                                 |
| <type=fixed>                              | type [*required*]                    | enum                | Type "fixed" denotes a fixed span. Allowed enum values: `fixed`                                                                                                                                                                                                                                                                       |
| definition                                | title                                     | string              | Title of your widget.                                                                                                                                                                                                                                                                                                                 |
| definition                                | title_align                               | enum                | How to align the text on the widget. Allowed enum values: `center,left,right`                                                                                                                                                                                                                                                         |
| definition                                | title_size                                | string              | Size of the title.                                                                                                                                                                                                                                                                                                                    |
| definition                                | type [*required*]                    | enum                | Type of the timeseries widget. Allowed enum values: `timeseries`                                                                                                                                                                                                                                                                      |
| definition                                | yaxis                                     | object              | Axis controls for the widget.                                                                                                                                                                                                                                                                                                         |
| yaxis                                     | include_zero                              | boolean             | Set to `true` to include zero.                                                                                                                                                                                                                                                                                                        |
| yaxis                                     | label                                     | string              | The label of the axis to display on the graph. Only usable on Scatterplot Widgets.                                                                                                                                                                                                                                                    |
| yaxis                                     | max                                       | string              | Specifies maximum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| yaxis                                     | min                                       | string              | Specifies minimum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| yaxis                                     | scale                                     | string              | Specifies the scale type. Possible values are `linear`, `log`, `sqrt`, and `pow##` (for example `pow2` or `pow0.5`).                                                                                                                                                                                                                  |
| Object 2                                  | graph_size                                | enum                | The size of the graph. Allowed enum values: `xs,s,m,l,xl`                                                                                                                                                                                                                                                                             |
| Object 2                                  | split_by                                  | object              | Object describing how to split the graph to display multiple visualizations per request.                                                                                                                                                                                                                                              |
| split_by                                  | keys [*required*]                    | [string]            | Keys to split on.                                                                                                                                                                                                                                                                                                                     |
| split_by                                  | tags [*required*]                    | [string]            | Tags to split on.                                                                                                                                                                                                                                                                                                                     |
| Object 2                                  | time                                      | object <oneOf> | Timeframe for the notebook cell. When 'null', the notebook global time is used.                                                                                                                                                                                                                                                       |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| attributes                                | Object 3                                  | object              | The attributes of a notebook `toplist` cell.                                                                                                                                                                                                                                                                                          |
| Object 3                                  | definition [*required*]              | object              | The top list visualization enables you to display a list of Tag value like hostname or service with the most or least of any metric value, such as highest consumers of CPU, hosts with the least disk space, etc.                                                                                                                    |
| definition                                | custom_links                              | [object]            | List of custom links.                                                                                                                                                                                                                                                                                                                 |
| custom_links                              | is_hidden                                 | boolean             | The flag for toggling context menu link visibility.                                                                                                                                                                                                                                                                                   |
| custom_links                              | label                                     | string              | The label for the custom link URL. Keep the label short and descriptive. Use metrics and tags as variables.                                                                                                                                                                                                                           |
| custom_links                              | link                                      | string              | The URL of the custom link. URL must include `http` or `https`. A relative URL must start with `/`.                                                                                                                                                                                                                                   |
| custom_links                              | override_label                            | string              | The label ID that refers to a context menu link. Can be `logs`, `hosts`, `traces`, `profiles`, `processes`, `containers`, or `rum`.                                                                                                                                                                                                   |
| definition                                | description                               | string              | The description of the widget.                                                                                                                                                                                                                                                                                                        |
| definition                                | requests [*required*]                | [object]            | List of top list widget requests.                                                                                                                                                                                                                                                                                                     |
| requests                                  | apm_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| apm_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| apm_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| apm_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | audit_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| audit_query                               | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| audit_query                               | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| audit_query                               | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| audit_query                               | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| audit_query                               | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | conditional_formats                       | [object]            | List of conditional formats.                                                                                                                                                                                                                                                                                                          |
| conditional_formats                       | comparator [*required*]              | enum                | Comparator to apply. Allowed enum values: `=,>,>=,<,<=`                                                                                                                                                                                                                                                                               |
| conditional_formats                       | custom_bg_color                           | string              | Color palette to apply to the background, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | custom_fg_color                           | string              | Color palette to apply to the foreground, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | hide_value                                | boolean             | True hides values.                                                                                                                                                                                                                                                                                                                    |
| conditional_formats                       | image_url                                 | string              | Displays an image as the background.                                                                                                                                                                                                                                                                                                  |
| conditional_formats                       | metric                                    | string              | Metric from the request to correlate this conditional format with.                                                                                                                                                                                                                                                                    |
| conditional_formats                       | palette [*required*]                 | enum                | Color palette to apply. Allowed enum values: `blue,custom_bg,custom_image,custom_text,gray_on_white,grey,green,orange,red,red_on_white`                                                                                                                                                                                               |
| conditional_formats                       | timeframe                                 | string              | Defines the displayed timeframe.                                                                                                                                                                                                                                                                                                      |
| conditional_formats                       | value [*required*]                   | double              | Value for the comparator.                                                                                                                                                                                                                                                                                                             |
| requests                                  | event_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| event_query                               | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| event_query                               | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| event_query                               | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | formulas                                  | [object]            | List of formulas that operate on queries.                                                                                                                                                                                                                                                                                             |
| formulas                                  | alias                                     | string              | Expression alias.                                                                                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode                         | enum                | Define a display mode for the table cell. Allowed enum values: `number,bar,trend`                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode_options                 | object              | Cell display mode options for the widget formula. (only if `cell_display_mode` is set to `trend`).                                                                                                                                                                                                                                    |
| cell_display_mode_options                 | trend_type                                | enum                | Trend type for the cell display mode options. Allowed enum values: `area,line,bars`                                                                                                                                                                                                                                                   |
| cell_display_mode_options                 | y_scale                                   | enum                | Y scale for the cell display mode options. Allowed enum values: `shared,independent`                                                                                                                                                                                                                                                  |
| formulas                                  | conditional_formats                       | [object]            | List of conditional formats.                                                                                                                                                                                                                                                                                                          |
| conditional_formats                       | comparator [*required*]              | enum                | Comparator to apply. Allowed enum values: `=,>,>=,<,<=`                                                                                                                                                                                                                                                                               |
| conditional_formats                       | custom_bg_color                           | string              | Color palette to apply to the background, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | custom_fg_color                           | string              | Color palette to apply to the foreground, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | hide_value                                | boolean             | True hides values.                                                                                                                                                                                                                                                                                                                    |
| conditional_formats                       | image_url                                 | string              | Displays an image as the background.                                                                                                                                                                                                                                                                                                  |
| conditional_formats                       | metric                                    | string              | Metric from the request to correlate this conditional format with.                                                                                                                                                                                                                                                                    |
| conditional_formats                       | palette [*required*]                 | enum                | Color palette to apply. Allowed enum values: `blue,custom_bg,custom_image,custom_text,gray_on_white,grey,green,orange,red,red_on_white`                                                                                                                                                                                               |
| conditional_formats                       | timeframe                                 | string              | Defines the displayed timeframe.                                                                                                                                                                                                                                                                                                      |
| conditional_formats                       | value [*required*]                   | double              | Value for the comparator.                                                                                                                                                                                                                                                                                                             |
| formulas                                  | formula [*required*]                 | string              | String expression built from queries, formulas, and functions.                                                                                                                                                                                                                                                                        |
| formulas                                  | limit                                     | object              | Options for limiting results returned.                                                                                                                                                                                                                                                                                                |
| limit                                     | count                                     | int64               | Number of results to return.                                                                                                                                                                                                                                                                                                          |
| limit                                     | order                                     | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| formulas                                  | number_format                             | object              | Number format options for the widget.                                                                                                                                                                                                                                                                                                 |
| number_format                             | unit                                      |  <oneOf>       | Number format unit.                                                                                                                                                                                                                                                                                                                   |
| unit                                      | <type=canonical_unit>                     | object              | Canonical unit.                                                                                                                                                                                                                                                                                                                       |
| unit                                      | <type=custom_unit_label>                  | object              | Custom unit.                                                                                                                                                                                                                                                                                                                          |
| number_format                             | unit_scale                                | object              | The definition of `NumberFormatUnitScale` object.                                                                                                                                                                                                                                                                                     |
| unit_scale                                | type                                      | enum                | The type of unit scale. Allowed enum values: `canonical_unit`                                                                                                                                                                                                                                                                         |
| unit_scale                                | unit_name                                 | string              | The name of the unit.                                                                                                                                                                                                                                                                                                                 |
| formulas                                  | style                                     | object              | Styling options for widget formulas.                                                                                                                                                                                                                                                                                                  |
| style                                     | palette                                   | string              | The color palette used to display the formula. A guide to the available color palettes can be found at [https://docs.datadoghq.com/dashboards/guide/widget_colors](https://docs.datadoghq.com/dashboards/guide/widget_colors.md)                                                                                                      |
| style                                     | palette_index                             | int64               | Index specifying which color to use within the palette.                                                                                                                                                                                                                                                                               |
| requests                                  | log_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| log_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| log_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| log_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | network_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| network_query                             | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| network_query                             | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| network_query                             | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | process_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| process_query                             | filter_by                                 | [string]            | List of processes.                                                                                                                                                                                                                                                                                                                    |
| process_query                             | limit                                     | int64               | Max number of items in the filter list.                                                                                                                                                                                                                                                                                               |
| process_query                             | metric [*required*]                  | string              | Your chosen metric.                                                                                                                                                                                                                                                                                                                   |
| process_query                             | search_by                                 | string              | Your chosen search term.                                                                                                                                                                                                                                                                                                              |
| requests                                  | profile_metrics_query                     | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| profile_metrics_query                     | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| profile_metrics_query                     | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | q                                         | string              | **DEPRECATED**: Widget query. Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                      |
| requests                                  | queries                                   | [ <oneOf>]     | List of queries that can be returned directly or used in formulas.                                                                                                                                                                                                                                                                    |
| queries                                   | <data_source=metrics>                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| <data_source=metrics>                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=metrics>                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| <data_source=metrics>                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| <data_source=metrics>                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| queries                                   | Object 2                                  | object              | A formula and functions events query.                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | compute [*required*]                 | object              | Compute options.                                                                                                                                                                                                                                                                                                                      |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | int64               | A time interval in milliseconds.                                                                                                                                                                                                                                                                                                      |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| Object 2                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 2                                  | data_source [*required*]             | enum                | Data source for event platform-based queries. Allowed enum values: `logs,spans,network,rum,security_signals,profiles,audit,events,ci_tests,ci_pipelines`                                                                                                                                                                              |
| Object 2                                  | group_by                                  |  <oneOf>       | Group by configuration for a formula and functions events query. Accepts either a list of facet objects or a flat object that specifies a list of facet fields.                                                                                                                                                                       |
| group_by                                  | Object 1                                  | [object]            | List of objects used to group by.                                                                                                                                                                                                                                                                                                     |
| group_by                                  | Object 2                                  | object              | Flat group by configuration using multiple event facet fields.                                                                                                                                                                                                                                                                        |
| Object 2                                  | indexes                                   | [string]            | An array of index names to query in the stream. Omit or use `[]` to query all indexes at once.                                                                                                                                                                                                                                        |
| Object 2                                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| Object 2                                  | search                                    | object              | Search options.                                                                                                                                                                                                                                                                                                                       |
| search                                    | query [*required*]                   | string              | Events search string.                                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | storage                                   | string              | Option for storage location. Feature in Private Beta.                                                                                                                                                                                                                                                                                 |
| queries                                   | Object 3                                  | object              | Process query using formulas and functions.                                                                                                                                                                                                                                                                                           |
| Object 3                                  | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| Object 3                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 3                                  | data_source [*required*]             | enum                | Data sources that rely on the process backend. Allowed enum values: `process,container`                                                                                                                                                                                                                                               |
| Object 3                                  | is_normalized_cpu                         | boolean             | Whether to normalize the CPU percentages.                                                                                                                                                                                                                                                                                             |
| Object 3                                  | limit                                     | int64               | Number of hits to return.                                                                                                                                                                                                                                                                                                             |
| Object 3                                  | metric [*required*]                  | string              | Process metric name.                                                                                                                                                                                                                                                                                                                  |
| Object 3                                  | name [*required*]                    | string              | Name of query for use in formulas.                                                                                                                                                                                                                                                                                                    |
| Object 3                                  | sort                                      | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| Object 3                                  | tag_filters                               | [string]            | An array of tags to filter by.                                                                                                                                                                                                                                                                                                        |
| Object 3                                  | text_filter                               | string              | Text to use as filter.                                                                                                                                                                                                                                                                                                                |
| queries                                   | <data_source=apm_dependency_stats>        | object              | A formula and functions APM dependency stats query.                                                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | data_source [*required*]             | enum                | Data source for APM dependency stats queries. Allowed enum values: `apm_dependency_stats`                                                                                                                                                                                                                                             |
| <data_source=apm_dependency_stats>        | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_dependency_stats>        | is_upstream                               | boolean             | Determines whether stats for upstream or downstream dependencies should be queried.                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | name [*required*]                    | string              | Name of query to use in formulas.                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_dependency_stats>        | operation_name [*required*]          | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | primary_tag_name                          | string              | The name of the second primary tag used within APM; required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog). |
| <data_source=apm_dependency_stats>        | primary_tag_value                         | string              | Filter APM data by the second primary tag. `primary_tag_name` must also be specified.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | resource_name [*required*]           | string              | APM resource.                                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | service [*required*]                 | string              | APM service.                                                                                                                                                                                                                                                                                                                          |
| <data_source=apm_dependency_stats>        | stat [*required*]                    | enum                | APM statistic. Allowed enum values: `avg_duration,avg_root_duration,avg_spans_per_trace,error_rate,pct_exec_time,pct_of_traces,total_traces_count`                                                                                                                                                                                    |
| queries                                   | <data_source=apm_resource_stats>          | object              | **DEPRECATED**: APM resource stats query using formulas and functions. Deprecated - Use `apm_metrics` query type instead.                                                                                                                                                                                                             |
| <data_source=apm_resource_stats>          | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | data_source [*required*]             | enum                | Data source for APM resource stats queries. Allowed enum values: `apm_resource_stats`                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_resource_stats>          | group_by                                  | [string]            | Array of fields to group results by.                                                                                                                                                                                                                                                                                                  |
| <data_source=apm_resource_stats>          | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_resource_stats>          | operation_name                            | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_resource_stats>          | primary_tag_name                          | string              | Name of the second primary tag used within APM. Required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog)      |
| <data_source=apm_resource_stats>          | primary_tag_value                         | string              | Value of the second primary tag by which to filter APM data. `primary_tag_name` must also be specified.                                                                                                                                                                                                                               |
| <data_source=apm_resource_stats>          | resource_name                             | string              | APM resource name.                                                                                                                                                                                                                                                                                                                    |
| <data_source=apm_resource_stats>          | service [*required*]                 | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_resource_stats>          | stat [*required*]                    | enum                | APM resource stat name. Allowed enum values: `errors,error_rate,hits,latency_avg,latency_distribution,latency_max,latency_p50,latency_p75,latency_p90,latency_p95`                                                                                                                                                                    |
| queries                                   | <data_source=apm_metrics>                 | object              | A formula and functions APM metrics query.                                                                                                                                                                                                                                                                                            |
| <data_source=apm_metrics>                 | data_source [*required*]             | enum                | Data source for APM metrics queries. Allowed enum values: `apm_metrics`                                                                                                                                                                                                                                                               |
| <data_source=apm_metrics>                 | group_by                                  | [string]            | Optional fields to group the query results by.                                                                                                                                                                                                                                                                                        |
| <data_source=apm_metrics>                 | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_metrics>                 | operation_mode                            | string              | Optional operation mode to aggregate across operation names.                                                                                                                                                                                                                                                                          |
| <data_source=apm_metrics>                 | operation_name                            | string              | Name of operation on service. If not provided, the primary operation name is used.                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | peer_tags                                 | [string]            | Tags to query for a specific downstream entity (peer.service, peer.db_instance, peer.s3, peer.s3.bucket, etc.).                                                                                                                                                                                                                       |
| <data_source=apm_metrics>                 | query_filter                              | string              | Additional filters for the query using metrics query syntax (e.g., env, primary_tag).                                                                                                                                                                                                                                                 |
| <data_source=apm_metrics>                 | resource_hash                             | string              | The hash of a specific resource to filter by.                                                                                                                                                                                                                                                                                         |
| <data_source=apm_metrics>                 | resource_name                             | string              | The full name of a specific resource to filter by.                                                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | service                                   | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_metrics>                 | span_kind                                 | enum                | Describes the relationship between the span, its parents, and its children in a trace. Allowed enum values: `consumer,server,client,producer,internal`                                                                                                                                                                                |
| <data_source=apm_metrics>                 | stat [*required*]                    | enum                | APM metric stat name. Allowed enum values: `errors,error_rate,errors_per_second,latency_avg,latency_max,latency_p50,latency_p75,latency_p90,latency_p95,latency_p99`                                                                                                                                                                  |
| queries                                   | <data_source=slo>                         | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | additional_query_filters                  | string              | Additional filters applied to the SLO query.                                                                                                                                                                                                                                                                                          |
| <data_source=slo>                         | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=slo>                         | data_source [*required*]             | enum                | Data source for SLO measures queries. Allowed enum values: `slo`                                                                                                                                                                                                                                                                      |
| <data_source=slo>                         | group_mode                                | enum                | Group mode to query measures. Allowed enum values: `overall,components`                                                                                                                                                                                                                                                               |
| <data_source=slo>                         | measure [*required*]                 | enum                | SLO measures queries. Allowed enum values: `good_events,bad_events,good_minutes,bad_minutes,slo_status,error_budget_remaining,burn_rate,error_budget_burndown`                                                                                                                                                                        |
| <data_source=slo>                         | name                                      | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | slo_id [*required*]                  | string              | ID of an SLO to query measures.                                                                                                                                                                                                                                                                                                       |
| <data_source=slo>                         | slo_query_type                            | enum                | Name of the query for use in formulas. Allowed enum values: `metric,monitor,time_slice`                                                                                                                                                                                                                                               |
| queries                                   | <data_source=cloud_cost>                  | object              | A formula and functions Cloud Cost query.                                                                                                                                                                                                                                                                                             |
| <data_source=cloud_cost>                  | aggregator                                | enum                | Aggregator used for the request. Allowed enum values: `avg,last,max,min,sum,percentile`                                                                                                                                                                                                                                               |
| <data_source=cloud_cost>                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | data_source [*required*]             | enum                | Data source for Cloud Cost queries. Allowed enum values: `cloud_cost`                                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=cloud_cost>                  | query [*required*]                   | string              | Query for Cloud Cost data.                                                                                                                                                                                                                                                                                                            |
| queries                                   | <data_source=product_analytics_extended>  | object              | A formula and functions Product Analytics Extended query for advanced analytics features.                                                                                                                                                                                                                                             |
| <data_source=product_analytics_extended>  | audience_filters                          | object              | Product Analytics/RUM audience filters.                                                                                                                                                                                                                                                                                               |
| audience_filters                          | accounts                                  | [object]            |
| audience_filters                          | filter_condition                          | string              | An optional filter condition applied to the audience subquery.                                                                                                                                                                                                                                                                        |
| audience_filters                          | segments                                  | [object]            |
| audience_filters                          | users                                     | [object]            |
| <data_source=product_analytics_extended>  | compute [*required*]                 | object              | Compute configuration for Product Analytics Extended queries.                                                                                                                                                                                                                                                                         |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Fixed-width time bucket interval in milliseconds for time series queries. Mutually exclusive with `rollup`.                                                                                                                                                                                                                           |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| compute                                   | name                                      | string              | Name of the compute for use in formulas.                                                                                                                                                                                                                                                                                              |
| compute                                   | rollup                                    | object              | Calendar-aligned time bucket for time series queries (for example, day, week, or month boundaries). Mutually exclusive with `interval`.                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | data_source [*required*]             | enum                | Data source for Product Analytics Extended queries. Allowed enum values: `product_analytics_extended`                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | indexes                                   | [string]            | Event indexes to query.                                                                                                                                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_extended>  | query [*required*]                   | object              | Base query for Product Analytics.                                                                                                                                                                                                                                                                                                     |
| query                                     | data_source [*required*]             | enum                | Data source for Product Analytics event queries. Allowed enum values: `product_analytics`                                                                                                                                                                                                                                             |
| query                                     | search [*required*]                  | object              | Search configuration for Product Analytics event query.                                                                                                                                                                                                                                                                               |
| queries                                   | <data_source=product_analytics_journey>   | object              | A formula and functions User Journey query for defining funnel, timeseries, and scalar visualizations over journey data.                                                                                                                                                                                                              |
| <data_source=product_analytics_journey>   | compute [*required*]                 | object              | Compute configuration for User Journey formula queries.                                                                                                                                                                                                                                                                               |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Time bucket interval in milliseconds for time series queries.                                                                                                                                                                                                                                                                         |
| compute                                   | metric                                    | enum                | Metric for User Journey formula compute. `__dd.conversion` and `__dd.conversion_rate` accept `count` and `cardinality` as aggregations. `__dd.time_to_convert` accepts `avg`, `median`, `pc75`, `pc95`, `pc98`, `pc99`, `min`, and `max`. Allowed enum values: `__dd.conversion,__dd.conversion_rate,__dd.time_to_convert`            |
| compute                                   | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | data_source [*required*]             | enum                | Data source for user journey funnel queries. Allowed enum values: `product_analytics_journey`                                                                                                                                                                                                                                         |
| <data_source=product_analytics_journey>   | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_journey>   | search [*required*]                  | object              | User journey search configuration.                                                                                                                                                                                                                                                                                                    |
| search                                    | expression [*required*]              | string              | Expression string.                                                                                                                                                                                                                                                                                                                    |
| search                                    | filters                                   | object              | Filters for user journey search.                                                                                                                                                                                                                                                                                                      |
| search                                    | join_keys                                 | object              | Join keys for user journey queries.                                                                                                                                                                                                                                                                                                   |
| search                                    | node_objects [*required*]            | object              | Node objects mapping.                                                                                                                                                                                                                                                                                                                 |
| search                                    | step_aliases                              | object              | Step aliases mapping.                                                                                                                                                                                                                                                                                                                 |
| queries                                   | <data_source=product_analytics_retention> | object              | A formula and functions Retention query for defining timeseries and scalar visualizations.                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | compute [*required*]                 | object              | Compute configuration for retention queries.                                                                                                                                                                                                                                                                                          |
| compute                                   | aggregation [*required*]             |  <oneOf>       | The type of aggregation that can be performed on events-based queries.                                                                                                                                                                                                                                                                |
| compute                                   | metric [*required*]                  | enum                | Metric for retention compute. Allowed enum values: `__dd.retention,__dd.retention_rate`                                                                                                                                                                                                                                               |
| <data_source=product_analytics_retention> | data_source [*required*]             | enum                | Data source for retention queries. Allowed enum values: `product_analytics_retention`                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_retention> | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet to group by.                                                                                                                                                                                                                                                                                                                    |
| group_by                                  | limit                                     | int64               | Maximum number of groups.                                                                                                                                                                                                                                                                                                             |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude missing values.                                                                                                                                                                                                                                                                                                    |
| group_by                                  | sort                                      | object              | Sort configuration for retention group by.                                                                                                                                                                                                                                                                                            |
| group_by                                  | source                                    | string              | Source field.                                                                                                                                                                                                                                                                                                                         |
| group_by                                  | target [*required*]                  | enum                | Target for retention group by. Allowed enum values: `cohort,return_period`                                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_retention> | search [*required*]                  | object              | Search configuration for retention queries.                                                                                                                                                                                                                                                                                           |
| search                                    | cohort_criteria [*required*]         | object              | Cohort criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| search                                    | filters                                   | object              | Filters for retention queries.                                                                                                                                                                                                                                                                                                        |
| search                                    | retention_entity [*required*]        | enum                | Entity to track for retention. Allowed enum values: `@usr.id,@account.id`                                                                                                                                                                                                                                                             |
| search                                    | return_condition [*required*]        | enum                | Condition for counting user return. Allowed enum values: `conversion_on,conversion_on_or_after`                                                                                                                                                                                                                                       |
| search                                    | return_criteria                           | object              | Return criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| requests                                  | response_format                           | enum                | Timeseries, scalar, or event list response. Event list response formats are supported by Geomap widgets. Allowed enum values: `timeseries,scalar,event_list`                                                                                                                                                                          |
| requests                                  | rum_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| rum_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| rum_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| rum_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | security_query                            | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| security_query                            | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| security_query                            | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| security_query                            | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | sort                                      | object              | The controls for sorting the widget.                                                                                                                                                                                                                                                                                                  |
| sort                                      | count                                     | int64               | The number of items to limit the widget to.                                                                                                                                                                                                                                                                                           |
| sort                                      | order_by                                  | [ <oneOf>]     | The array of items to sort the widget by in order.                                                                                                                                                                                                                                                                                    |
| order_by                                  | <type=formula>                            | object              | The formula to sort the widget by.                                                                                                                                                                                                                                                                                                    |
| <type=formula>                            | index [*required*]                   | int64               | The index of the formula to sort by.                                                                                                                                                                                                                                                                                                  |
| <type=formula>                            | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| <type=formula>                            | type [*required*]                    | enum                | Set the sort type to formula. Allowed enum values: `formula`                                                                                                                                                                                                                                                                          |
| order_by                                  | <type=group>                              | object              | The group to sort the widget by.                                                                                                                                                                                                                                                                                                      |
| <type=group>                              | name [*required*]                    | string              | The name of the group.                                                                                                                                                                                                                                                                                                                |
| <type=group>                              | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| <type=group>                              | type [*required*]                    | enum                | Set the sort type to group. Allowed enum values: `group`                                                                                                                                                                                                                                                                              |
| requests                                  | style                                     | object              | Define request widget style.                                                                                                                                                                                                                                                                                                          |
| style                                     | line_type                                 | enum                | Type of lines displayed. Allowed enum values: `dashed,dotted,solid`                                                                                                                                                                                                                                                                   |
| style                                     | line_width                                | enum                | Width of line displayed. Allowed enum values: `normal,thick,thin`                                                                                                                                                                                                                                                                     |
| style                                     | order_by                                  | enum                | How to order series in timeseries visualizations.                                                                                                                                                                                                                                                                                     |
| style                                     | palette                                   | string              | Color palette to apply to the widget.                                                                                                                                                                                                                                                                                                 |
| definition                                | style                                     | object              | Style customization for a top list widget.                                                                                                                                                                                                                                                                                            |
| style                                     | display                                   |  <oneOf>       | Top list widget display options.                                                                                                                                                                                                                                                                                                      |
| display                                   | <type=stacked>                            | object              | Top list widget stacked display options.                                                                                                                                                                                                                                                                                              |
| <type=stacked>                            | legend                                    | enum                | Top list widget stacked legend behavior. Allowed enum values: `automatic,inline,none`                                                                                                                                                                                                                                                 |
| <type=stacked>                            | type [*required*]                    | enum                | Top list widget stacked display type. Allowed enum values: `stacked`                                                                                                                                                                                                                                                                  |
| display                                   | <type=flat>                               | object              | Top list widget flat display.                                                                                                                                                                                                                                                                                                         |
| <type=flat>                               | type [*required*]                    | enum                | Top list widget flat display type. Allowed enum values: `flat`                                                                                                                                                                                                                                                                        |
| style                                     | palette                                   | string              | Color palette to apply to the widget.                                                                                                                                                                                                                                                                                                 |
| style                                     | scaling                                   | enum                | Top list widget scaling definition. Allowed enum values: `absolute,relative`                                                                                                                                                                                                                                                          |
| definition                                | time                                      |  <oneOf>       | Time setting for the widget.                                                                                                                                                                                                                                                                                                          |
| time                                      | Object 1                                  | object              | Wrapper for live span                                                                                                                                                                                                                                                                                                                 |
| Object 1                                  | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span                                 | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | <type=live>                               | object              | Used for arbitrary live span times, such as 17 minutes or 6 hours.                                                                                                                                                                                                                                                                    |
| <type=live>                               | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=live>                               | type [*required*]                    | enum                | Type "live" denotes a live span in the new format. Allowed enum values: `live`                                                                                                                                                                                                                                                        |
| <type=live>                               | unit [*required*]                    | enum                | Unit of the time span. Allowed enum values: `minute,hour,day,week,month,year`                                                                                                                                                                                                                                                         |
| <type=live>                               | value [*required*]                   | int64               | Value of the time span.                                                                                                                                                                                                                                                                                                               |
| time                                      | <type=fixed>                              | object              | Used for fixed span times, such as 'March 1 to March 7'.                                                                                                                                                                                                                                                                              |
| <type=fixed>                              | from [*required*]                    | int64               | Start time in milliseconds since epoch.                                                                                                                                                                                                                                                                                               |
| <type=fixed>                              | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=fixed>                              | to [*required*]                      | int64               | End time in milliseconds since epoch.                                                                                                                                                                                                                                                                                                 |
| <type=fixed>                              | type [*required*]                    | enum                | Type "fixed" denotes a fixed span. Allowed enum values: `fixed`                                                                                                                                                                                                                                                                       |
| definition                                | title                                     | string              | Title of your widget.                                                                                                                                                                                                                                                                                                                 |
| definition                                | title_align                               | enum                | How to align the text on the widget. Allowed enum values: `center,left,right`                                                                                                                                                                                                                                                         |
| definition                                | title_size                                | string              | Size of the title.                                                                                                                                                                                                                                                                                                                    |
| definition                                | type [*required*]                    | enum                | Type of the top list widget. Allowed enum values: `toplist`                                                                                                                                                                                                                                                                           |
| Object 3                                  | graph_size                                | enum                | The size of the graph. Allowed enum values: `xs,s,m,l,xl`                                                                                                                                                                                                                                                                             |
| Object 3                                  | split_by                                  | object              | Object describing how to split the graph to display multiple visualizations per request.                                                                                                                                                                                                                                              |
| split_by                                  | keys [*required*]                    | [string]            | Keys to split on.                                                                                                                                                                                                                                                                                                                     |
| split_by                                  | tags [*required*]                    | [string]            | Tags to split on.                                                                                                                                                                                                                                                                                                                     |
| Object 3                                  | time                                      | object <oneOf> | Timeframe for the notebook cell. When 'null', the notebook global time is used.                                                                                                                                                                                                                                                       |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| attributes                                | Object 4                                  | object              | The attributes of a notebook `heatmap` cell.                                                                                                                                                                                                                                                                                          |
| Object 4                                  | definition [*required*]              | object              | The heat map visualization shows metrics aggregated across many tags, such as hosts. The more hosts that have a particular value, the darker that square is.                                                                                                                                                                          |
| definition                                | custom_links                              | [object]            | List of custom links.                                                                                                                                                                                                                                                                                                                 |
| custom_links                              | is_hidden                                 | boolean             | The flag for toggling context menu link visibility.                                                                                                                                                                                                                                                                                   |
| custom_links                              | label                                     | string              | The label for the custom link URL. Keep the label short and descriptive. Use metrics and tags as variables.                                                                                                                                                                                                                           |
| custom_links                              | link                                      | string              | The URL of the custom link. URL must include `http` or `https`. A relative URL must start with `/`.                                                                                                                                                                                                                                   |
| custom_links                              | override_label                            | string              | The label ID that refers to a context menu link. Can be `logs`, `hosts`, `traces`, `profiles`, `processes`, `containers`, or `rum`.                                                                                                                                                                                                   |
| definition                                | description                               | string              | The description of the widget.                                                                                                                                                                                                                                                                                                        |
| definition                                | events                                    | [object]            | **DEPRECATED**: List of widget events. Deprecated - Use `overlay` request type instead.                                                                                                                                                                                                                                               |
| events                                    | q [*required*]                       | string              | Query definition.                                                                                                                                                                                                                                                                                                                     |
| events                                    | tags_execution                            | string              | The execution method for multi-value filters.                                                                                                                                                                                                                                                                                         |
| definition                                | legend_size                               | string              | Available legend sizes for a widget. Should be one of "0", "2", "4", "8", "16", or "auto".                                                                                                                                                                                                                                            |
| definition                                | markers                                   | [object]            | List of markers.                                                                                                                                                                                                                                                                                                                      |
| markers                                   | display_type                              | string              | Combination of:                                                                                                                                                                                                                                                                                                                       |
| markers                                   | label                                     | string              | Label to display over the marker.                                                                                                                                                                                                                                                                                                     |
| markers                                   | time                                      | string              | Timestamp for the widget.                                                                                                                                                                                                                                                                                                             |
| markers                                   | value [*required*]                   | string              | Value to apply. Can be a single value y = 15 or a range of values 0 < y < 10. For Distribution widgets with `display_type` set to `percentile`, this should be a numeric percentile value (for example, "90" for P90).                                                                                                                |
| definition                                | requests [*required*]                | [object]            | List of widget types.                                                                                                                                                                                                                                                                                                                 |
| requests                                  | apm_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| apm_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| apm_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| apm_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | event_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| event_query                               | search [*required*]                  | string              | The query being made on the event.                                                                                                                                                                                                                                                                                                    |
| event_query                               | tags_execution [*required*]          | string              | The execution method for multi-value filters. Can be either and or or.                                                                                                                                                                                                                                                                |
| requests                                  | formulas                                  | [object]            | List of formulas that operate on queries.                                                                                                                                                                                                                                                                                             |
| formulas                                  | alias                                     | string              | Expression alias.                                                                                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode                         | enum                | Define a display mode for the table cell. Allowed enum values: `number,bar,trend`                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode_options                 | object              | Cell display mode options for the widget formula. (only if `cell_display_mode` is set to `trend`).                                                                                                                                                                                                                                    |
| cell_display_mode_options                 | trend_type                                | enum                | Trend type for the cell display mode options. Allowed enum values: `area,line,bars`                                                                                                                                                                                                                                                   |
| cell_display_mode_options                 | y_scale                                   | enum                | Y scale for the cell display mode options. Allowed enum values: `shared,independent`                                                                                                                                                                                                                                                  |
| formulas                                  | conditional_formats                       | [object]            | List of conditional formats.                                                                                                                                                                                                                                                                                                          |
| conditional_formats                       | comparator [*required*]              | enum                | Comparator to apply. Allowed enum values: `=,>,>=,<,<=`                                                                                                                                                                                                                                                                               |
| conditional_formats                       | custom_bg_color                           | string              | Color palette to apply to the background, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | custom_fg_color                           | string              | Color palette to apply to the foreground, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | hide_value                                | boolean             | True hides values.                                                                                                                                                                                                                                                                                                                    |
| conditional_formats                       | image_url                                 | string              | Displays an image as the background.                                                                                                                                                                                                                                                                                                  |
| conditional_formats                       | metric                                    | string              | Metric from the request to correlate this conditional format with.                                                                                                                                                                                                                                                                    |
| conditional_formats                       | palette [*required*]                 | enum                | Color palette to apply. Allowed enum values: `blue,custom_bg,custom_image,custom_text,gray_on_white,grey,green,orange,red,red_on_white`                                                                                                                                                                                               |
| conditional_formats                       | timeframe                                 | string              | Defines the displayed timeframe.                                                                                                                                                                                                                                                                                                      |
| conditional_formats                       | value [*required*]                   | double              | Value for the comparator.                                                                                                                                                                                                                                                                                                             |
| formulas                                  | formula [*required*]                 | string              | String expression built from queries, formulas, and functions.                                                                                                                                                                                                                                                                        |
| formulas                                  | limit                                     | object              | Options for limiting results returned.                                                                                                                                                                                                                                                                                                |
| limit                                     | count                                     | int64               | Number of results to return.                                                                                                                                                                                                                                                                                                          |
| limit                                     | order                                     | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| formulas                                  | number_format                             | object              | Number format options for the widget.                                                                                                                                                                                                                                                                                                 |
| number_format                             | unit                                      |  <oneOf>       | Number format unit.                                                                                                                                                                                                                                                                                                                   |
| unit                                      | <type=canonical_unit>                     | object              | Canonical unit.                                                                                                                                                                                                                                                                                                                       |
| unit                                      | <type=custom_unit_label>                  | object              | Custom unit.                                                                                                                                                                                                                                                                                                                          |
| number_format                             | unit_scale                                | object              | The definition of `NumberFormatUnitScale` object.                                                                                                                                                                                                                                                                                     |
| unit_scale                                | type                                      | enum                | The type of unit scale. Allowed enum values: `canonical_unit`                                                                                                                                                                                                                                                                         |
| unit_scale                                | unit_name                                 | string              | The name of the unit.                                                                                                                                                                                                                                                                                                                 |
| formulas                                  | style                                     | object              | Styling options for widget formulas.                                                                                                                                                                                                                                                                                                  |
| style                                     | palette                                   | string              | The color palette used to display the formula. A guide to the available color palettes can be found at [https://docs.datadoghq.com/dashboards/guide/widget_colors](https://docs.datadoghq.com/dashboards/guide/widget_colors.md)                                                                                                      |
| style                                     | palette_index                             | int64               | Index specifying which color to use within the palette.                                                                                                                                                                                                                                                                               |
| requests                                  | log_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| log_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| log_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| log_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | network_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| network_query                             | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| network_query                             | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| network_query                             | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | process_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| process_query                             | filter_by                                 | [string]            | List of processes.                                                                                                                                                                                                                                                                                                                    |
| process_query                             | limit                                     | int64               | Max number of items in the filter list.                                                                                                                                                                                                                                                                                               |
| process_query                             | metric [*required*]                  | string              | Your chosen metric.                                                                                                                                                                                                                                                                                                                   |
| process_query                             | search_by                                 | string              | Your chosen search term.                                                                                                                                                                                                                                                                                                              |
| requests                                  | profile_metrics_query                     | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| profile_metrics_query                     | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| profile_metrics_query                     | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | q                                         | string              | **DEPRECATED**: Widget query. Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                      |
| requests                                  | queries                                   | [ <oneOf>]     | List of queries that can be returned directly or used in formulas.                                                                                                                                                                                                                                                                    |
| queries                                   | <data_source=metrics>                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| <data_source=metrics>                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=metrics>                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| <data_source=metrics>                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| <data_source=metrics>                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| queries                                   | Object 2                                  | object              | A formula and functions events query.                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | compute [*required*]                 | object              | Compute options.                                                                                                                                                                                                                                                                                                                      |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | int64               | A time interval in milliseconds.                                                                                                                                                                                                                                                                                                      |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| Object 2                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 2                                  | data_source [*required*]             | enum                | Data source for event platform-based queries. Allowed enum values: `logs,spans,network,rum,security_signals,profiles,audit,events,ci_tests,ci_pipelines`                                                                                                                                                                              |
| Object 2                                  | group_by                                  |  <oneOf>       | Group by configuration for a formula and functions events query. Accepts either a list of facet objects or a flat object that specifies a list of facet fields.                                                                                                                                                                       |
| group_by                                  | Object 1                                  | [object]            | List of objects used to group by.                                                                                                                                                                                                                                                                                                     |
| group_by                                  | Object 2                                  | object              | Flat group by configuration using multiple event facet fields.                                                                                                                                                                                                                                                                        |
| Object 2                                  | indexes                                   | [string]            | An array of index names to query in the stream. Omit or use `[]` to query all indexes at once.                                                                                                                                                                                                                                        |
| Object 2                                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| Object 2                                  | search                                    | object              | Search options.                                                                                                                                                                                                                                                                                                                       |
| search                                    | query [*required*]                   | string              | Events search string.                                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | storage                                   | string              | Option for storage location. Feature in Private Beta.                                                                                                                                                                                                                                                                                 |
| queries                                   | Object 3                                  | object              | Process query using formulas and functions.                                                                                                                                                                                                                                                                                           |
| Object 3                                  | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| Object 3                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 3                                  | data_source [*required*]             | enum                | Data sources that rely on the process backend. Allowed enum values: `process,container`                                                                                                                                                                                                                                               |
| Object 3                                  | is_normalized_cpu                         | boolean             | Whether to normalize the CPU percentages.                                                                                                                                                                                                                                                                                             |
| Object 3                                  | limit                                     | int64               | Number of hits to return.                                                                                                                                                                                                                                                                                                             |
| Object 3                                  | metric [*required*]                  | string              | Process metric name.                                                                                                                                                                                                                                                                                                                  |
| Object 3                                  | name [*required*]                    | string              | Name of query for use in formulas.                                                                                                                                                                                                                                                                                                    |
| Object 3                                  | sort                                      | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| Object 3                                  | tag_filters                               | [string]            | An array of tags to filter by.                                                                                                                                                                                                                                                                                                        |
| Object 3                                  | text_filter                               | string              | Text to use as filter.                                                                                                                                                                                                                                                                                                                |
| queries                                   | <data_source=apm_dependency_stats>        | object              | A formula and functions APM dependency stats query.                                                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | data_source [*required*]             | enum                | Data source for APM dependency stats queries. Allowed enum values: `apm_dependency_stats`                                                                                                                                                                                                                                             |
| <data_source=apm_dependency_stats>        | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_dependency_stats>        | is_upstream                               | boolean             | Determines whether stats for upstream or downstream dependencies should be queried.                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | name [*required*]                    | string              | Name of query to use in formulas.                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_dependency_stats>        | operation_name [*required*]          | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | primary_tag_name                          | string              | The name of the second primary tag used within APM; required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog). |
| <data_source=apm_dependency_stats>        | primary_tag_value                         | string              | Filter APM data by the second primary tag. `primary_tag_name` must also be specified.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | resource_name [*required*]           | string              | APM resource.                                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | service [*required*]                 | string              | APM service.                                                                                                                                                                                                                                                                                                                          |
| <data_source=apm_dependency_stats>        | stat [*required*]                    | enum                | APM statistic. Allowed enum values: `avg_duration,avg_root_duration,avg_spans_per_trace,error_rate,pct_exec_time,pct_of_traces,total_traces_count`                                                                                                                                                                                    |
| queries                                   | <data_source=apm_resource_stats>          | object              | **DEPRECATED**: APM resource stats query using formulas and functions. Deprecated - Use `apm_metrics` query type instead.                                                                                                                                                                                                             |
| <data_source=apm_resource_stats>          | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | data_source [*required*]             | enum                | Data source for APM resource stats queries. Allowed enum values: `apm_resource_stats`                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_resource_stats>          | group_by                                  | [string]            | Array of fields to group results by.                                                                                                                                                                                                                                                                                                  |
| <data_source=apm_resource_stats>          | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_resource_stats>          | operation_name                            | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_resource_stats>          | primary_tag_name                          | string              | Name of the second primary tag used within APM. Required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog)      |
| <data_source=apm_resource_stats>          | primary_tag_value                         | string              | Value of the second primary tag by which to filter APM data. `primary_tag_name` must also be specified.                                                                                                                                                                                                                               |
| <data_source=apm_resource_stats>          | resource_name                             | string              | APM resource name.                                                                                                                                                                                                                                                                                                                    |
| <data_source=apm_resource_stats>          | service [*required*]                 | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_resource_stats>          | stat [*required*]                    | enum                | APM resource stat name. Allowed enum values: `errors,error_rate,hits,latency_avg,latency_distribution,latency_max,latency_p50,latency_p75,latency_p90,latency_p95`                                                                                                                                                                    |
| queries                                   | <data_source=apm_metrics>                 | object              | A formula and functions APM metrics query.                                                                                                                                                                                                                                                                                            |
| <data_source=apm_metrics>                 | data_source [*required*]             | enum                | Data source for APM metrics queries. Allowed enum values: `apm_metrics`                                                                                                                                                                                                                                                               |
| <data_source=apm_metrics>                 | group_by                                  | [string]            | Optional fields to group the query results by.                                                                                                                                                                                                                                                                                        |
| <data_source=apm_metrics>                 | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_metrics>                 | operation_mode                            | string              | Optional operation mode to aggregate across operation names.                                                                                                                                                                                                                                                                          |
| <data_source=apm_metrics>                 | operation_name                            | string              | Name of operation on service. If not provided, the primary operation name is used.                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | peer_tags                                 | [string]            | Tags to query for a specific downstream entity (peer.service, peer.db_instance, peer.s3, peer.s3.bucket, etc.).                                                                                                                                                                                                                       |
| <data_source=apm_metrics>                 | query_filter                              | string              | Additional filters for the query using metrics query syntax (e.g., env, primary_tag).                                                                                                                                                                                                                                                 |
| <data_source=apm_metrics>                 | resource_hash                             | string              | The hash of a specific resource to filter by.                                                                                                                                                                                                                                                                                         |
| <data_source=apm_metrics>                 | resource_name                             | string              | The full name of a specific resource to filter by.                                                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | service                                   | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_metrics>                 | span_kind                                 | enum                | Describes the relationship between the span, its parents, and its children in a trace. Allowed enum values: `consumer,server,client,producer,internal`                                                                                                                                                                                |
| <data_source=apm_metrics>                 | stat [*required*]                    | enum                | APM metric stat name. Allowed enum values: `errors,error_rate,errors_per_second,latency_avg,latency_max,latency_p50,latency_p75,latency_p90,latency_p95,latency_p99`                                                                                                                                                                  |
| queries                                   | <data_source=slo>                         | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | additional_query_filters                  | string              | Additional filters applied to the SLO query.                                                                                                                                                                                                                                                                                          |
| <data_source=slo>                         | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=slo>                         | data_source [*required*]             | enum                | Data source for SLO measures queries. Allowed enum values: `slo`                                                                                                                                                                                                                                                                      |
| <data_source=slo>                         | group_mode                                | enum                | Group mode to query measures. Allowed enum values: `overall,components`                                                                                                                                                                                                                                                               |
| <data_source=slo>                         | measure [*required*]                 | enum                | SLO measures queries. Allowed enum values: `good_events,bad_events,good_minutes,bad_minutes,slo_status,error_budget_remaining,burn_rate,error_budget_burndown`                                                                                                                                                                        |
| <data_source=slo>                         | name                                      | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | slo_id [*required*]                  | string              | ID of an SLO to query measures.                                                                                                                                                                                                                                                                                                       |
| <data_source=slo>                         | slo_query_type                            | enum                | Name of the query for use in formulas. Allowed enum values: `metric,monitor,time_slice`                                                                                                                                                                                                                                               |
| queries                                   | <data_source=cloud_cost>                  | object              | A formula and functions Cloud Cost query.                                                                                                                                                                                                                                                                                             |
| <data_source=cloud_cost>                  | aggregator                                | enum                | Aggregator used for the request. Allowed enum values: `avg,last,max,min,sum,percentile`                                                                                                                                                                                                                                               |
| <data_source=cloud_cost>                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | data_source [*required*]             | enum                | Data source for Cloud Cost queries. Allowed enum values: `cloud_cost`                                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=cloud_cost>                  | query [*required*]                   | string              | Query for Cloud Cost data.                                                                                                                                                                                                                                                                                                            |
| queries                                   | <data_source=product_analytics_extended>  | object              | A formula and functions Product Analytics Extended query for advanced analytics features.                                                                                                                                                                                                                                             |
| <data_source=product_analytics_extended>  | audience_filters                          | object              | Product Analytics/RUM audience filters.                                                                                                                                                                                                                                                                                               |
| audience_filters                          | accounts                                  | [object]            |
| audience_filters                          | filter_condition                          | string              | An optional filter condition applied to the audience subquery.                                                                                                                                                                                                                                                                        |
| audience_filters                          | segments                                  | [object]            |
| audience_filters                          | users                                     | [object]            |
| <data_source=product_analytics_extended>  | compute [*required*]                 | object              | Compute configuration for Product Analytics Extended queries.                                                                                                                                                                                                                                                                         |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Fixed-width time bucket interval in milliseconds for time series queries. Mutually exclusive with `rollup`.                                                                                                                                                                                                                           |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| compute                                   | name                                      | string              | Name of the compute for use in formulas.                                                                                                                                                                                                                                                                                              |
| compute                                   | rollup                                    | object              | Calendar-aligned time bucket for time series queries (for example, day, week, or month boundaries). Mutually exclusive with `interval`.                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | data_source [*required*]             | enum                | Data source for Product Analytics Extended queries. Allowed enum values: `product_analytics_extended`                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | indexes                                   | [string]            | Event indexes to query.                                                                                                                                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_extended>  | query [*required*]                   | object              | Base query for Product Analytics.                                                                                                                                                                                                                                                                                                     |
| query                                     | data_source [*required*]             | enum                | Data source for Product Analytics event queries. Allowed enum values: `product_analytics`                                                                                                                                                                                                                                             |
| query                                     | search [*required*]                  | object              | Search configuration for Product Analytics event query.                                                                                                                                                                                                                                                                               |
| queries                                   | <data_source=product_analytics_journey>   | object              | A formula and functions User Journey query for defining funnel, timeseries, and scalar visualizations over journey data.                                                                                                                                                                                                              |
| <data_source=product_analytics_journey>   | compute [*required*]                 | object              | Compute configuration for User Journey formula queries.                                                                                                                                                                                                                                                                               |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Time bucket interval in milliseconds for time series queries.                                                                                                                                                                                                                                                                         |
| compute                                   | metric                                    | enum                | Metric for User Journey formula compute. `__dd.conversion` and `__dd.conversion_rate` accept `count` and `cardinality` as aggregations. `__dd.time_to_convert` accepts `avg`, `median`, `pc75`, `pc95`, `pc98`, `pc99`, `min`, and `max`. Allowed enum values: `__dd.conversion,__dd.conversion_rate,__dd.time_to_convert`            |
| compute                                   | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | data_source [*required*]             | enum                | Data source for user journey funnel queries. Allowed enum values: `product_analytics_journey`                                                                                                                                                                                                                                         |
| <data_source=product_analytics_journey>   | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_journey>   | search [*required*]                  | object              | User journey search configuration.                                                                                                                                                                                                                                                                                                    |
| search                                    | expression [*required*]              | string              | Expression string.                                                                                                                                                                                                                                                                                                                    |
| search                                    | filters                                   | object              | Filters for user journey search.                                                                                                                                                                                                                                                                                                      |
| search                                    | join_keys                                 | object              | Join keys for user journey queries.                                                                                                                                                                                                                                                                                                   |
| search                                    | node_objects [*required*]            | object              | Node objects mapping.                                                                                                                                                                                                                                                                                                                 |
| search                                    | step_aliases                              | object              | Step aliases mapping.                                                                                                                                                                                                                                                                                                                 |
| queries                                   | <data_source=product_analytics_retention> | object              | A formula and functions Retention query for defining timeseries and scalar visualizations.                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | compute [*required*]                 | object              | Compute configuration for retention queries.                                                                                                                                                                                                                                                                                          |
| compute                                   | aggregation [*required*]             |  <oneOf>       | The type of aggregation that can be performed on events-based queries.                                                                                                                                                                                                                                                                |
| compute                                   | metric [*required*]                  | enum                | Metric for retention compute. Allowed enum values: `__dd.retention,__dd.retention_rate`                                                                                                                                                                                                                                               |
| <data_source=product_analytics_retention> | data_source [*required*]             | enum                | Data source for retention queries. Allowed enum values: `product_analytics_retention`                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_retention> | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet to group by.                                                                                                                                                                                                                                                                                                                    |
| group_by                                  | limit                                     | int64               | Maximum number of groups.                                                                                                                                                                                                                                                                                                             |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude missing values.                                                                                                                                                                                                                                                                                                    |
| group_by                                  | sort                                      | object              | Sort configuration for retention group by.                                                                                                                                                                                                                                                                                            |
| group_by                                  | source                                    | string              | Source field.                                                                                                                                                                                                                                                                                                                         |
| group_by                                  | target [*required*]                  | enum                | Target for retention group by. Allowed enum values: `cohort,return_period`                                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_retention> | search [*required*]                  | object              | Search configuration for retention queries.                                                                                                                                                                                                                                                                                           |
| search                                    | cohort_criteria [*required*]         | object              | Cohort criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| search                                    | filters                                   | object              | Filters for retention queries.                                                                                                                                                                                                                                                                                                        |
| search                                    | retention_entity [*required*]        | enum                | Entity to track for retention. Allowed enum values: `@usr.id,@account.id`                                                                                                                                                                                                                                                             |
| search                                    | return_condition [*required*]        | enum                | Condition for counting user return. Allowed enum values: `conversion_on,conversion_on_or_after`                                                                                                                                                                                                                                       |
| search                                    | return_criteria                           | object              | Return criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| requests                                  | query                                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| query                                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| query                                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| query                                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| query                                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| query                                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| query                                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| requests                                  | request_type                              | enum                | Applicable only for distribution of point values for distribution metrics. Allowed enum values: `histogram`                                                                                                                                                                                                                           |
| requests                                  | response_format                           | enum                | Applicable only for distribution of aggregated grouped queries. Allowed enum values: `timeseries,scalar,event_list`                                                                                                                                                                                                                   |
| requests                                  | rum_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| rum_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| rum_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| rum_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | security_query                            | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| security_query                            | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| security_query                            | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| security_query                            | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | style                                     | object              | Widget style definition.                                                                                                                                                                                                                                                                                                              |
| style                                     | palette                                   | string              | Color palette to apply to the widget.                                                                                                                                                                                                                                                                                                 |
| definition                                | show_legend                               | boolean             | Whether or not to display the legend on this widget.                                                                                                                                                                                                                                                                                  |
| definition                                | time                                      |  <oneOf>       | Time setting for the widget.                                                                                                                                                                                                                                                                                                          |
| time                                      | Object 1                                  | object              | Wrapper for live span                                                                                                                                                                                                                                                                                                                 |
| Object 1                                  | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span                                 | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | <type=live>                               | object              | Used for arbitrary live span times, such as 17 minutes or 6 hours.                                                                                                                                                                                                                                                                    |
| <type=live>                               | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=live>                               | type [*required*]                    | enum                | Type "live" denotes a live span in the new format. Allowed enum values: `live`                                                                                                                                                                                                                                                        |
| <type=live>                               | unit [*required*]                    | enum                | Unit of the time span. Allowed enum values: `minute,hour,day,week,month,year`                                                                                                                                                                                                                                                         |
| <type=live>                               | value [*required*]                   | int64               | Value of the time span.                                                                                                                                                                                                                                                                                                               |
| time                                      | <type=fixed>                              | object              | Used for fixed span times, such as 'March 1 to March 7'.                                                                                                                                                                                                                                                                              |
| <type=fixed>                              | from [*required*]                    | int64               | Start time in milliseconds since epoch.                                                                                                                                                                                                                                                                                               |
| <type=fixed>                              | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=fixed>                              | to [*required*]                      | int64               | End time in milliseconds since epoch.                                                                                                                                                                                                                                                                                                 |
| <type=fixed>                              | type [*required*]                    | enum                | Type "fixed" denotes a fixed span. Allowed enum values: `fixed`                                                                                                                                                                                                                                                                       |
| definition                                | title                                     | string              | Title of the widget.                                                                                                                                                                                                                                                                                                                  |
| definition                                | title_align                               | enum                | How to align the text on the widget. Allowed enum values: `center,left,right`                                                                                                                                                                                                                                                         |
| definition                                | title_size                                | string              | Size of the title.                                                                                                                                                                                                                                                                                                                    |
| definition                                | type [*required*]                    | enum                | Type of the heat map widget. Allowed enum values: `heatmap`                                                                                                                                                                                                                                                                           |
| definition                                | xaxis                                     | object              | X Axis controls for the heat map widget.                                                                                                                                                                                                                                                                                              |
| xaxis                                     | num_buckets                               | int64               | Number of time buckets to target, also known as the resolution of the time bins. This is only applicable for distribution of points (group distributions use the roll-up modifier).                                                                                                                                                   |
| definition                                | yaxis                                     | object              | Axis controls for the widget.                                                                                                                                                                                                                                                                                                         |
| yaxis                                     | include_zero                              | boolean             | Set to `true` to include zero.                                                                                                                                                                                                                                                                                                        |
| yaxis                                     | label                                     | string              | The label of the axis to display on the graph. Only usable on Scatterplot Widgets.                                                                                                                                                                                                                                                    |
| yaxis                                     | max                                       | string              | Specifies maximum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| yaxis                                     | min                                       | string              | Specifies minimum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| yaxis                                     | scale                                     | string              | Specifies the scale type. Possible values are `linear`, `log`, `sqrt`, and `pow##` (for example `pow2` or `pow0.5`).                                                                                                                                                                                                                  |
| Object 4                                  | graph_size                                | enum                | The size of the graph. Allowed enum values: `xs,s,m,l,xl`                                                                                                                                                                                                                                                                             |
| Object 4                                  | split_by                                  | object              | Object describing how to split the graph to display multiple visualizations per request.                                                                                                                                                                                                                                              |
| split_by                                  | keys [*required*]                    | [string]            | Keys to split on.                                                                                                                                                                                                                                                                                                                     |
| split_by                                  | tags [*required*]                    | [string]            | Tags to split on.                                                                                                                                                                                                                                                                                                                     |
| Object 4                                  | time                                      | object <oneOf> | Timeframe for the notebook cell. When 'null', the notebook global time is used.                                                                                                                                                                                                                                                       |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| attributes                                | Object 5                                  | object              | The attributes of a notebook `distribution` cell.                                                                                                                                                                                                                                                                                     |
| Object 5                                  | definition [*required*]              | object              | The Distribution visualization is another way of showing metrics aggregated across one or several tags, such as hosts. Unlike the heat map, a distribution graph's x-axis is quantity rather than time.                                                                                                                               |
| definition                                | custom_links                              | [object]            | A list of custom links.                                                                                                                                                                                                                                                                                                               |
| custom_links                              | is_hidden                                 | boolean             | The flag for toggling context menu link visibility.                                                                                                                                                                                                                                                                                   |
| custom_links                              | label                                     | string              | The label for the custom link URL. Keep the label short and descriptive. Use metrics and tags as variables.                                                                                                                                                                                                                           |
| custom_links                              | link                                      | string              | The URL of the custom link. URL must include `http` or `https`. A relative URL must start with `/`.                                                                                                                                                                                                                                   |
| custom_links                              | override_label                            | string              | The label ID that refers to a context menu link. Can be `logs`, `hosts`, `traces`, `profiles`, `processes`, `containers`, or `rum`.                                                                                                                                                                                                   |
| definition                                | description                               | string              | The description of the widget.                                                                                                                                                                                                                                                                                                        |
| definition                                | legend_size                               | string              | **DEPRECATED**: (Deprecated) The widget legend was replaced by a tooltip and sidebar.                                                                                                                                                                                                                                                 |
| definition                                | markers                                   | [object]            | List of markers.                                                                                                                                                                                                                                                                                                                      |
| markers                                   | display_type                              | string              | Combination of:                                                                                                                                                                                                                                                                                                                       |
| markers                                   | label                                     | string              | Label to display over the marker.                                                                                                                                                                                                                                                                                                     |
| markers                                   | time                                      | string              | Timestamp for the widget.                                                                                                                                                                                                                                                                                                             |
| markers                                   | value [*required*]                   | string              | Value to apply. Can be a single value y = 15 or a range of values 0 < y < 10. For Distribution widgets with `display_type` set to `percentile`, this should be a numeric percentile value (for example, "90" for P90).                                                                                                                |
| definition                                | requests [*required*]                | [object]            | Array of one request object to display in the widget.                                                                                                                                                                                                                                                                                 | See the dedicated [Request JSON schema documentation](https://docs.datadoghq.com/dashboards/graphing_json/request_json.md) to learn how to build the `REQUEST_SCHEMA`. |
| requests                                  | apm_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| apm_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| apm_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| apm_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | apm_stats_query                           | object              | The APM stats query for table and distributions widgets.                                                                                                                                                                                                                                                                              |
| apm_stats_query                           | columns                                   | [object]            | Column properties used by the front end for display.                                                                                                                                                                                                                                                                                  |
| columns                                   | alias                                     | string              | A user-assigned alias for the column.                                                                                                                                                                                                                                                                                                 |
| columns                                   | cell_display_mode                         | enum                | Define a display mode for the table cell. Allowed enum values: `number,bar,trend`                                                                                                                                                                                                                                                     |
| columns                                   | name [*required*]                    | string              | Column name.                                                                                                                                                                                                                                                                                                                          |
| columns                                   | order                                     | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| apm_stats_query                           | env [*required*]                     | string              | Environment name.                                                                                                                                                                                                                                                                                                                     |
| apm_stats_query                           | name [*required*]                    | string              | Operation name associated with service.                                                                                                                                                                                                                                                                                               |
| apm_stats_query                           | primary_tag [*required*]             | string              | The organization's host group name and value.                                                                                                                                                                                                                                                                                         |
| apm_stats_query                           | resource                                  | string              | Resource name.                                                                                                                                                                                                                                                                                                                        |
| apm_stats_query                           | row_type [*required*]                | enum                | The level of detail for the request. Allowed enum values: `service,resource,span`                                                                                                                                                                                                                                                     |
| apm_stats_query                           | service [*required*]                 | string              | Service name.                                                                                                                                                                                                                                                                                                                         |
| requests                                  | event_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| event_query                               | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| event_query                               | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| event_query                               | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | formulas                                  | [object]            | List of formulas that operate on queries.                                                                                                                                                                                                                                                                                             |
| formulas                                  | alias                                     | string              | Expression alias.                                                                                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode                         | enum                | Define a display mode for the table cell. Allowed enum values: `number,bar,trend`                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode_options                 | object              | Cell display mode options for the widget formula. (only if `cell_display_mode` is set to `trend`).                                                                                                                                                                                                                                    |
| cell_display_mode_options                 | trend_type                                | enum                | Trend type for the cell display mode options. Allowed enum values: `area,line,bars`                                                                                                                                                                                                                                                   |
| cell_display_mode_options                 | y_scale                                   | enum                | Y scale for the cell display mode options. Allowed enum values: `shared,independent`                                                                                                                                                                                                                                                  |
| formulas                                  | conditional_formats                       | [object]            | List of conditional formats.                                                                                                                                                                                                                                                                                                          |
| conditional_formats                       | comparator [*required*]              | enum                | Comparator to apply. Allowed enum values: `=,>,>=,<,<=`                                                                                                                                                                                                                                                                               |
| conditional_formats                       | custom_bg_color                           | string              | Color palette to apply to the background, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | custom_fg_color                           | string              | Color palette to apply to the foreground, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | hide_value                                | boolean             | True hides values.                                                                                                                                                                                                                                                                                                                    |
| conditional_formats                       | image_url                                 | string              | Displays an image as the background.                                                                                                                                                                                                                                                                                                  |
| conditional_formats                       | metric                                    | string              | Metric from the request to correlate this conditional format with.                                                                                                                                                                                                                                                                    |
| conditional_formats                       | palette [*required*]                 | enum                | Color palette to apply. Allowed enum values: `blue,custom_bg,custom_image,custom_text,gray_on_white,grey,green,orange,red,red_on_white`                                                                                                                                                                                               |
| conditional_formats                       | timeframe                                 | string              | Defines the displayed timeframe.                                                                                                                                                                                                                                                                                                      |
| conditional_formats                       | value [*required*]                   | double              | Value for the comparator.                                                                                                                                                                                                                                                                                                             |
| formulas                                  | formula [*required*]                 | string              | String expression built from queries, formulas, and functions.                                                                                                                                                                                                                                                                        |
| formulas                                  | limit                                     | object              | Options for limiting results returned.                                                                                                                                                                                                                                                                                                |
| limit                                     | count                                     | int64               | Number of results to return.                                                                                                                                                                                                                                                                                                          |
| limit                                     | order                                     | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| formulas                                  | number_format                             | object              | Number format options for the widget.                                                                                                                                                                                                                                                                                                 |
| number_format                             | unit                                      |  <oneOf>       | Number format unit.                                                                                                                                                                                                                                                                                                                   |
| unit                                      | <type=canonical_unit>                     | object              | Canonical unit.                                                                                                                                                                                                                                                                                                                       |
| unit                                      | <type=custom_unit_label>                  | object              | Custom unit.                                                                                                                                                                                                                                                                                                                          |
| number_format                             | unit_scale                                | object              | The definition of `NumberFormatUnitScale` object.                                                                                                                                                                                                                                                                                     |
| unit_scale                                | type                                      | enum                | The type of unit scale. Allowed enum values: `canonical_unit`                                                                                                                                                                                                                                                                         |
| unit_scale                                | unit_name                                 | string              | The name of the unit.                                                                                                                                                                                                                                                                                                                 |
| formulas                                  | style                                     | object              | Styling options for widget formulas.                                                                                                                                                                                                                                                                                                  |
| style                                     | palette                                   | string              | The color palette used to display the formula. A guide to the available color palettes can be found at [https://docs.datadoghq.com/dashboards/guide/widget_colors](https://docs.datadoghq.com/dashboards/guide/widget_colors.md)                                                                                                      |
| style                                     | palette_index                             | int64               | Index specifying which color to use within the palette.                                                                                                                                                                                                                                                                               |
| requests                                  | log_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| log_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| log_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| log_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | network_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| network_query                             | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| network_query                             | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| network_query                             | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | process_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| process_query                             | filter_by                                 | [string]            | List of processes.                                                                                                                                                                                                                                                                                                                    |
| process_query                             | limit                                     | int64               | Max number of items in the filter list.                                                                                                                                                                                                                                                                                               |
| process_query                             | metric [*required*]                  | string              | Your chosen metric.                                                                                                                                                                                                                                                                                                                   |
| process_query                             | search_by                                 | string              | Your chosen search term.                                                                                                                                                                                                                                                                                                              |
| requests                                  | profile_metrics_query                     | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| profile_metrics_query                     | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| profile_metrics_query                     | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | q                                         | string              | **DEPRECATED**: Widget query. Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                      |
| requests                                  | queries                                   | [ <oneOf>]     | List of queries that can be returned directly or used in formulas.                                                                                                                                                                                                                                                                    |
| queries                                   | <data_source=metrics>                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| <data_source=metrics>                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=metrics>                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| <data_source=metrics>                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| <data_source=metrics>                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| queries                                   | Object 2                                  | object              | A formula and functions events query.                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | compute [*required*]                 | object              | Compute options.                                                                                                                                                                                                                                                                                                                      |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | int64               | A time interval in milliseconds.                                                                                                                                                                                                                                                                                                      |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| Object 2                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 2                                  | data_source [*required*]             | enum                | Data source for event platform-based queries. Allowed enum values: `logs,spans,network,rum,security_signals,profiles,audit,events,ci_tests,ci_pipelines`                                                                                                                                                                              |
| Object 2                                  | group_by                                  |  <oneOf>       | Group by configuration for a formula and functions events query. Accepts either a list of facet objects or a flat object that specifies a list of facet fields.                                                                                                                                                                       |
| group_by                                  | Object 1                                  | [object]            | List of objects used to group by.                                                                                                                                                                                                                                                                                                     |
| group_by                                  | Object 2                                  | object              | Flat group by configuration using multiple event facet fields.                                                                                                                                                                                                                                                                        |
| Object 2                                  | indexes                                   | [string]            | An array of index names to query in the stream. Omit or use `[]` to query all indexes at once.                                                                                                                                                                                                                                        |
| Object 2                                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| Object 2                                  | search                                    | object              | Search options.                                                                                                                                                                                                                                                                                                                       |
| search                                    | query [*required*]                   | string              | Events search string.                                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | storage                                   | string              | Option for storage location. Feature in Private Beta.                                                                                                                                                                                                                                                                                 |
| queries                                   | Object 3                                  | object              | Process query using formulas and functions.                                                                                                                                                                                                                                                                                           |
| Object 3                                  | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| Object 3                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 3                                  | data_source [*required*]             | enum                | Data sources that rely on the process backend. Allowed enum values: `process,container`                                                                                                                                                                                                                                               |
| Object 3                                  | is_normalized_cpu                         | boolean             | Whether to normalize the CPU percentages.                                                                                                                                                                                                                                                                                             |
| Object 3                                  | limit                                     | int64               | Number of hits to return.                                                                                                                                                                                                                                                                                                             |
| Object 3                                  | metric [*required*]                  | string              | Process metric name.                                                                                                                                                                                                                                                                                                                  |
| Object 3                                  | name [*required*]                    | string              | Name of query for use in formulas.                                                                                                                                                                                                                                                                                                    |
| Object 3                                  | sort                                      | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| Object 3                                  | tag_filters                               | [string]            | An array of tags to filter by.                                                                                                                                                                                                                                                                                                        |
| Object 3                                  | text_filter                               | string              | Text to use as filter.                                                                                                                                                                                                                                                                                                                |
| queries                                   | <data_source=apm_dependency_stats>        | object              | A formula and functions APM dependency stats query.                                                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | data_source [*required*]             | enum                | Data source for APM dependency stats queries. Allowed enum values: `apm_dependency_stats`                                                                                                                                                                                                                                             |
| <data_source=apm_dependency_stats>        | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_dependency_stats>        | is_upstream                               | boolean             | Determines whether stats for upstream or downstream dependencies should be queried.                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | name [*required*]                    | string              | Name of query to use in formulas.                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_dependency_stats>        | operation_name [*required*]          | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | primary_tag_name                          | string              | The name of the second primary tag used within APM; required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog). |
| <data_source=apm_dependency_stats>        | primary_tag_value                         | string              | Filter APM data by the second primary tag. `primary_tag_name` must also be specified.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | resource_name [*required*]           | string              | APM resource.                                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | service [*required*]                 | string              | APM service.                                                                                                                                                                                                                                                                                                                          |
| <data_source=apm_dependency_stats>        | stat [*required*]                    | enum                | APM statistic. Allowed enum values: `avg_duration,avg_root_duration,avg_spans_per_trace,error_rate,pct_exec_time,pct_of_traces,total_traces_count`                                                                                                                                                                                    |
| queries                                   | <data_source=apm_resource_stats>          | object              | **DEPRECATED**: APM resource stats query using formulas and functions. Deprecated - Use `apm_metrics` query type instead.                                                                                                                                                                                                             |
| <data_source=apm_resource_stats>          | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | data_source [*required*]             | enum                | Data source for APM resource stats queries. Allowed enum values: `apm_resource_stats`                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_resource_stats>          | group_by                                  | [string]            | Array of fields to group results by.                                                                                                                                                                                                                                                                                                  |
| <data_source=apm_resource_stats>          | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_resource_stats>          | operation_name                            | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_resource_stats>          | primary_tag_name                          | string              | Name of the second primary tag used within APM. Required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog)      |
| <data_source=apm_resource_stats>          | primary_tag_value                         | string              | Value of the second primary tag by which to filter APM data. `primary_tag_name` must also be specified.                                                                                                                                                                                                                               |
| <data_source=apm_resource_stats>          | resource_name                             | string              | APM resource name.                                                                                                                                                                                                                                                                                                                    |
| <data_source=apm_resource_stats>          | service [*required*]                 | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_resource_stats>          | stat [*required*]                    | enum                | APM resource stat name. Allowed enum values: `errors,error_rate,hits,latency_avg,latency_distribution,latency_max,latency_p50,latency_p75,latency_p90,latency_p95`                                                                                                                                                                    |
| queries                                   | <data_source=apm_metrics>                 | object              | A formula and functions APM metrics query.                                                                                                                                                                                                                                                                                            |
| <data_source=apm_metrics>                 | data_source [*required*]             | enum                | Data source for APM metrics queries. Allowed enum values: `apm_metrics`                                                                                                                                                                                                                                                               |
| <data_source=apm_metrics>                 | group_by                                  | [string]            | Optional fields to group the query results by.                                                                                                                                                                                                                                                                                        |
| <data_source=apm_metrics>                 | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_metrics>                 | operation_mode                            | string              | Optional operation mode to aggregate across operation names.                                                                                                                                                                                                                                                                          |
| <data_source=apm_metrics>                 | operation_name                            | string              | Name of operation on service. If not provided, the primary operation name is used.                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | peer_tags                                 | [string]            | Tags to query for a specific downstream entity (peer.service, peer.db_instance, peer.s3, peer.s3.bucket, etc.).                                                                                                                                                                                                                       |
| <data_source=apm_metrics>                 | query_filter                              | string              | Additional filters for the query using metrics query syntax (e.g., env, primary_tag).                                                                                                                                                                                                                                                 |
| <data_source=apm_metrics>                 | resource_hash                             | string              | The hash of a specific resource to filter by.                                                                                                                                                                                                                                                                                         |
| <data_source=apm_metrics>                 | resource_name                             | string              | The full name of a specific resource to filter by.                                                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | service                                   | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_metrics>                 | span_kind                                 | enum                | Describes the relationship between the span, its parents, and its children in a trace. Allowed enum values: `consumer,server,client,producer,internal`                                                                                                                                                                                |
| <data_source=apm_metrics>                 | stat [*required*]                    | enum                | APM metric stat name. Allowed enum values: `errors,error_rate,errors_per_second,latency_avg,latency_max,latency_p50,latency_p75,latency_p90,latency_p95,latency_p99`                                                                                                                                                                  |
| queries                                   | <data_source=slo>                         | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | additional_query_filters                  | string              | Additional filters applied to the SLO query.                                                                                                                                                                                                                                                                                          |
| <data_source=slo>                         | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=slo>                         | data_source [*required*]             | enum                | Data source for SLO measures queries. Allowed enum values: `slo`                                                                                                                                                                                                                                                                      |
| <data_source=slo>                         | group_mode                                | enum                | Group mode to query measures. Allowed enum values: `overall,components`                                                                                                                                                                                                                                                               |
| <data_source=slo>                         | measure [*required*]                 | enum                | SLO measures queries. Allowed enum values: `good_events,bad_events,good_minutes,bad_minutes,slo_status,error_budget_remaining,burn_rate,error_budget_burndown`                                                                                                                                                                        |
| <data_source=slo>                         | name                                      | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | slo_id [*required*]                  | string              | ID of an SLO to query measures.                                                                                                                                                                                                                                                                                                       |
| <data_source=slo>                         | slo_query_type                            | enum                | Name of the query for use in formulas. Allowed enum values: `metric,monitor,time_slice`                                                                                                                                                                                                                                               |
| queries                                   | <data_source=cloud_cost>                  | object              | A formula and functions Cloud Cost query.                                                                                                                                                                                                                                                                                             |
| <data_source=cloud_cost>                  | aggregator                                | enum                | Aggregator used for the request. Allowed enum values: `avg,last,max,min,sum,percentile`                                                                                                                                                                                                                                               |
| <data_source=cloud_cost>                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | data_source [*required*]             | enum                | Data source for Cloud Cost queries. Allowed enum values: `cloud_cost`                                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=cloud_cost>                  | query [*required*]                   | string              | Query for Cloud Cost data.                                                                                                                                                                                                                                                                                                            |
| queries                                   | <data_source=product_analytics_extended>  | object              | A formula and functions Product Analytics Extended query for advanced analytics features.                                                                                                                                                                                                                                             |
| <data_source=product_analytics_extended>  | audience_filters                          | object              | Product Analytics/RUM audience filters.                                                                                                                                                                                                                                                                                               |
| audience_filters                          | accounts                                  | [object]            |
| audience_filters                          | filter_condition                          | string              | An optional filter condition applied to the audience subquery.                                                                                                                                                                                                                                                                        |
| audience_filters                          | segments                                  | [object]            |
| audience_filters                          | users                                     | [object]            |
| <data_source=product_analytics_extended>  | compute [*required*]                 | object              | Compute configuration for Product Analytics Extended queries.                                                                                                                                                                                                                                                                         |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Fixed-width time bucket interval in milliseconds for time series queries. Mutually exclusive with `rollup`.                                                                                                                                                                                                                           |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| compute                                   | name                                      | string              | Name of the compute for use in formulas.                                                                                                                                                                                                                                                                                              |
| compute                                   | rollup                                    | object              | Calendar-aligned time bucket for time series queries (for example, day, week, or month boundaries). Mutually exclusive with `interval`.                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | data_source [*required*]             | enum                | Data source for Product Analytics Extended queries. Allowed enum values: `product_analytics_extended`                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | indexes                                   | [string]            | Event indexes to query.                                                                                                                                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_extended>  | query [*required*]                   | object              | Base query for Product Analytics.                                                                                                                                                                                                                                                                                                     |
| query                                     | data_source [*required*]             | enum                | Data source for Product Analytics event queries. Allowed enum values: `product_analytics`                                                                                                                                                                                                                                             |
| query                                     | search [*required*]                  | object              | Search configuration for Product Analytics event query.                                                                                                                                                                                                                                                                               |
| queries                                   | <data_source=product_analytics_journey>   | object              | A formula and functions User Journey query for defining funnel, timeseries, and scalar visualizations over journey data.                                                                                                                                                                                                              |
| <data_source=product_analytics_journey>   | compute [*required*]                 | object              | Compute configuration for User Journey formula queries.                                                                                                                                                                                                                                                                               |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Time bucket interval in milliseconds for time series queries.                                                                                                                                                                                                                                                                         |
| compute                                   | metric                                    | enum                | Metric for User Journey formula compute. `__dd.conversion` and `__dd.conversion_rate` accept `count` and `cardinality` as aggregations. `__dd.time_to_convert` accepts `avg`, `median`, `pc75`, `pc95`, `pc98`, `pc99`, `min`, and `max`. Allowed enum values: `__dd.conversion,__dd.conversion_rate,__dd.time_to_convert`            |
| compute                                   | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | data_source [*required*]             | enum                | Data source for user journey funnel queries. Allowed enum values: `product_analytics_journey`                                                                                                                                                                                                                                         |
| <data_source=product_analytics_journey>   | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_journey>   | search [*required*]                  | object              | User journey search configuration.                                                                                                                                                                                                                                                                                                    |
| search                                    | expression [*required*]              | string              | Expression string.                                                                                                                                                                                                                                                                                                                    |
| search                                    | filters                                   | object              | Filters for user journey search.                                                                                                                                                                                                                                                                                                      |
| search                                    | join_keys                                 | object              | Join keys for user journey queries.                                                                                                                                                                                                                                                                                                   |
| search                                    | node_objects [*required*]            | object              | Node objects mapping.                                                                                                                                                                                                                                                                                                                 |
| search                                    | step_aliases                              | object              | Step aliases mapping.                                                                                                                                                                                                                                                                                                                 |
| queries                                   | <data_source=product_analytics_retention> | object              | A formula and functions Retention query for defining timeseries and scalar visualizations.                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | compute [*required*]                 | object              | Compute configuration for retention queries.                                                                                                                                                                                                                                                                                          |
| compute                                   | aggregation [*required*]             |  <oneOf>       | The type of aggregation that can be performed on events-based queries.                                                                                                                                                                                                                                                                |
| compute                                   | metric [*required*]                  | enum                | Metric for retention compute. Allowed enum values: `__dd.retention,__dd.retention_rate`                                                                                                                                                                                                                                               |
| <data_source=product_analytics_retention> | data_source [*required*]             | enum                | Data source for retention queries. Allowed enum values: `product_analytics_retention`                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_retention> | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet to group by.                                                                                                                                                                                                                                                                                                                    |
| group_by                                  | limit                                     | int64               | Maximum number of groups.                                                                                                                                                                                                                                                                                                             |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude missing values.                                                                                                                                                                                                                                                                                                    |
| group_by                                  | sort                                      | object              | Sort configuration for retention group by.                                                                                                                                                                                                                                                                                            |
| group_by                                  | source                                    | string              | Source field.                                                                                                                                                                                                                                                                                                                         |
| group_by                                  | target [*required*]                  | enum                | Target for retention group by. Allowed enum values: `cohort,return_period`                                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_retention> | search [*required*]                  | object              | Search configuration for retention queries.                                                                                                                                                                                                                                                                                           |
| search                                    | cohort_criteria [*required*]         | object              | Cohort criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| search                                    | filters                                   | object              | Filters for retention queries.                                                                                                                                                                                                                                                                                                        |
| search                                    | retention_entity [*required*]        | enum                | Entity to track for retention. Allowed enum values: `@usr.id,@account.id`                                                                                                                                                                                                                                                             |
| search                                    | return_condition [*required*]        | enum                | Condition for counting user return. Allowed enum values: `conversion_on,conversion_on_or_after`                                                                                                                                                                                                                                       |
| search                                    | return_criteria                           | object              | Return criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| requests                                  | query                                     |  <oneOf>       | Query definition for Distribution Widget Histogram Request                                                                                                                                                                                                                                                                            |
| query                                     | <data_source=metrics>                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| <data_source=metrics>                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=metrics>                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| <data_source=metrics>                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| <data_source=metrics>                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| query                                     | Object 2                                  | object              | A formula and functions events query.                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | compute [*required*]                 | object              | Compute options.                                                                                                                                                                                                                                                                                                                      |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | int64               | A time interval in milliseconds.                                                                                                                                                                                                                                                                                                      |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| Object 2                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 2                                  | data_source [*required*]             | enum                | Data source for event platform-based queries. Allowed enum values: `logs,spans,network,rum,security_signals,profiles,audit,events,ci_tests,ci_pipelines`                                                                                                                                                                              |
| Object 2                                  | group_by                                  |  <oneOf>       | Group by configuration for a formula and functions events query. Accepts either a list of facet objects or a flat object that specifies a list of facet fields.                                                                                                                                                                       |
| group_by                                  | Object 1                                  | [object]            | List of objects used to group by.                                                                                                                                                                                                                                                                                                     |
| group_by                                  | Object 2                                  | object              | Flat group by configuration using multiple event facet fields.                                                                                                                                                                                                                                                                        |
| Object 2                                  | indexes                                   | [string]            | An array of index names to query in the stream. Omit or use `[]` to query all indexes at once.                                                                                                                                                                                                                                        |
| Object 2                                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| Object 2                                  | search                                    | object              | Search options.                                                                                                                                                                                                                                                                                                                       |
| search                                    | query [*required*]                   | string              | Events search string.                                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | storage                                   | string              | Option for storage location. Feature in Private Beta.                                                                                                                                                                                                                                                                                 |
| query                                     | <data_source=apm_resource_stats>          | object              | **DEPRECATED**: APM resource stats query using formulas and functions. Deprecated - Use `apm_metrics` query type instead.                                                                                                                                                                                                             |
| <data_source=apm_resource_stats>          | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | data_source [*required*]             | enum                | Data source for APM resource stats queries. Allowed enum values: `apm_resource_stats`                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_resource_stats>          | group_by                                  | [string]            | Array of fields to group results by.                                                                                                                                                                                                                                                                                                  |
| <data_source=apm_resource_stats>          | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_resource_stats>          | operation_name                            | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_resource_stats>          | primary_tag_name                          | string              | Name of the second primary tag used within APM. Required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog)      |
| <data_source=apm_resource_stats>          | primary_tag_value                         | string              | Value of the second primary tag by which to filter APM data. `primary_tag_name` must also be specified.                                                                                                                                                                                                                               |
| <data_source=apm_resource_stats>          | resource_name                             | string              | APM resource name.                                                                                                                                                                                                                                                                                                                    |
| <data_source=apm_resource_stats>          | service [*required*]                 | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_resource_stats>          | stat [*required*]                    | enum                | APM resource stat name. Allowed enum values: `errors,error_rate,hits,latency_avg,latency_distribution,latency_max,latency_p50,latency_p75,latency_p90,latency_p95`                                                                                                                                                                    |
| query                                     | <data_source=apm_metrics>                 | object              | A formula and functions APM metrics query.                                                                                                                                                                                                                                                                                            |
| <data_source=apm_metrics>                 | data_source [*required*]             | enum                | Data source for APM metrics queries. Allowed enum values: `apm_metrics`                                                                                                                                                                                                                                                               |
| <data_source=apm_metrics>                 | group_by                                  | [string]            | Optional fields to group the query results by.                                                                                                                                                                                                                                                                                        |
| <data_source=apm_metrics>                 | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_metrics>                 | operation_mode                            | string              | Optional operation mode to aggregate across operation names.                                                                                                                                                                                                                                                                          |
| <data_source=apm_metrics>                 | operation_name                            | string              | Name of operation on service. If not provided, the primary operation name is used.                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | peer_tags                                 | [string]            | Tags to query for a specific downstream entity (peer.service, peer.db_instance, peer.s3, peer.s3.bucket, etc.).                                                                                                                                                                                                                       |
| <data_source=apm_metrics>                 | query_filter                              | string              | Additional filters for the query using metrics query syntax (e.g., env, primary_tag).                                                                                                                                                                                                                                                 |
| <data_source=apm_metrics>                 | resource_hash                             | string              | The hash of a specific resource to filter by.                                                                                                                                                                                                                                                                                         |
| <data_source=apm_metrics>                 | resource_name                             | string              | The full name of a specific resource to filter by.                                                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | service                                   | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_metrics>                 | span_kind                                 | enum                | Describes the relationship between the span, its parents, and its children in a trace. Allowed enum values: `consumer,server,client,producer,internal`                                                                                                                                                                                |
| <data_source=apm_metrics>                 | stat [*required*]                    | enum                | APM metric stat name. Allowed enum values: `errors,error_rate,errors_per_second,latency_avg,latency_max,latency_p50,latency_p75,latency_p90,latency_p95,latency_p99`                                                                                                                                                                  |
| requests                                  | request_type                              | enum                | Distribution of point values for distribution metrics. Renders a histogram of raw metric data points. Allowed enum values: `histogram`                                                                                                                                                                                                |
| requests                                  | response_format                           | enum                | Distribution of aggregated grouped queries. Use `request_type` instead for distribution of point values from distribution metrics. Allowed enum values: `timeseries,scalar,event_list`                                                                                                                                                |
| requests                                  | rum_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| rum_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| rum_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| rum_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | security_query                            | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| security_query                            | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| security_query                            | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| security_query                            | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | style                                     | object              | Widget style definition.                                                                                                                                                                                                                                                                                                              |
| style                                     | palette                                   | string              | Color palette to apply to the widget.                                                                                                                                                                                                                                                                                                 |
| definition                                | show_legend                               | boolean             | **DEPRECATED**: (Deprecated) The widget legend was replaced by a tooltip and sidebar.                                                                                                                                                                                                                                                 |
| definition                                | time                                      |  <oneOf>       | Time setting for the widget.                                                                                                                                                                                                                                                                                                          |
| time                                      | Object 1                                  | object              | Wrapper for live span                                                                                                                                                                                                                                                                                                                 |
| Object 1                                  | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span                                 | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | <type=live>                               | object              | Used for arbitrary live span times, such as 17 minutes or 6 hours.                                                                                                                                                                                                                                                                    |
| <type=live>                               | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=live>                               | type [*required*]                    | enum                | Type "live" denotes a live span in the new format. Allowed enum values: `live`                                                                                                                                                                                                                                                        |
| <type=live>                               | unit [*required*]                    | enum                | Unit of the time span. Allowed enum values: `minute,hour,day,week,month,year`                                                                                                                                                                                                                                                         |
| <type=live>                               | value [*required*]                   | int64               | Value of the time span.                                                                                                                                                                                                                                                                                                               |
| time                                      | <type=fixed>                              | object              | Used for fixed span times, such as 'March 1 to March 7'.                                                                                                                                                                                                                                                                              |
| <type=fixed>                              | from [*required*]                    | int64               | Start time in milliseconds since epoch.                                                                                                                                                                                                                                                                                               |
| <type=fixed>                              | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=fixed>                              | to [*required*]                      | int64               | End time in milliseconds since epoch.                                                                                                                                                                                                                                                                                                 |
| <type=fixed>                              | type [*required*]                    | enum                | Type "fixed" denotes a fixed span. Allowed enum values: `fixed`                                                                                                                                                                                                                                                                       |
| definition                                | title                                     | string              | Title of the widget.                                                                                                                                                                                                                                                                                                                  |
| definition                                | title_align                               | enum                | How to align the text on the widget. Allowed enum values: `center,left,right`                                                                                                                                                                                                                                                         |
| definition                                | title_size                                | string              | Size of the title.                                                                                                                                                                                                                                                                                                                    |
| definition                                | type [*required*]                    | enum                | Type of the distribution widget. Allowed enum values: `distribution`                                                                                                                                                                                                                                                                  |
| definition                                | xaxis                                     | object              | X Axis controls for the distribution widget.                                                                                                                                                                                                                                                                                          |
| xaxis                                     | include_zero                              | boolean             | True includes zero.                                                                                                                                                                                                                                                                                                                   |
| xaxis                                     | max                                       | string              | Specifies maximum value to show on the x-axis. It takes a number, percentile (p90 === 90th percentile), or auto for default behavior.                                                                                                                                                                                                 |
| xaxis                                     | min                                       | string              | Specifies minimum value to show on the x-axis. It takes a number, percentile (p90 === 90th percentile), or auto for default behavior.                                                                                                                                                                                                 |
| xaxis                                     | num_buckets                               | int64               | Number of value buckets to target, also known as the resolution of the value bins.                                                                                                                                                                                                                                                    |
| xaxis                                     | scale                                     | string              | Specifies the scale type. Possible values are `linear`.                                                                                                                                                                                                                                                                               |
| definition                                | yaxis                                     | object              | Y Axis controls for the distribution widget.                                                                                                                                                                                                                                                                                          |
| yaxis                                     | include_zero                              | boolean             | True includes zero.                                                                                                                                                                                                                                                                                                                   |
| yaxis                                     | label                                     | string              | The label of the axis to display on the graph.                                                                                                                                                                                                                                                                                        |
| yaxis                                     | max                                       | string              | Specifies the maximum value to show on the y-axis. It takes a number, or auto for default behavior.                                                                                                                                                                                                                                   |
| yaxis                                     | min                                       | string              | Specifies minimum value to show on the y-axis. It takes a number, or auto for default behavior.                                                                                                                                                                                                                                       |
| yaxis                                     | scale                                     | string              | Specifies the scale type. Possible values are `linear` or `log`.                                                                                                                                                                                                                                                                      |
| Object 5                                  | graph_size                                | enum                | The size of the graph. Allowed enum values: `xs,s,m,l,xl`                                                                                                                                                                                                                                                                             |
| Object 5                                  | split_by                                  | object              | Object describing how to split the graph to display multiple visualizations per request.                                                                                                                                                                                                                                              |
| split_by                                  | keys [*required*]                    | [string]            | Keys to split on.                                                                                                                                                                                                                                                                                                                     |
| split_by                                  | tags [*required*]                    | [string]            | Tags to split on.                                                                                                                                                                                                                                                                                                                     |
| Object 5                                  | time                                      | object <oneOf> | Timeframe for the notebook cell. When 'null', the notebook global time is used.                                                                                                                                                                                                                                                       |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| attributes                                | Object 6                                  | object              | The attributes of a notebook `log_stream` cell.                                                                                                                                                                                                                                                                                       |
| Object 6                                  | definition [*required*]              | object              | The Log Stream displays a log flow matching the defined query.                                                                                                                                                                                                                                                                        |
| definition                                | columns                                   | [string]            | Which columns to display on the widget.                                                                                                                                                                                                                                                                                               |
| definition                                | description                               | string              | The description of the widget.                                                                                                                                                                                                                                                                                                        |
| definition                                | indexes                                   | [string]            | An array of index names to query in the stream. Use [] to query all indexes at once.                                                                                                                                                                                                                                                  |
| definition                                | logset                                    | string              | **DEPRECATED**: ID of the log set to use.                                                                                                                                                                                                                                                                                             |
| definition                                | message_display                           | enum                | Amount of log lines to display Allowed enum values: `inline,expanded-md,expanded-lg`                                                                                                                                                                                                                                                  |
| definition                                | query                                     | string              | Query to filter the log stream with.                                                                                                                                                                                                                                                                                                  |
| definition                                | show_date_column                          | boolean             | Whether to show the date column or not                                                                                                                                                                                                                                                                                                |
| definition                                | show_message_column                       | boolean             | Whether to show the message column or not                                                                                                                                                                                                                                                                                             |
| definition                                | sort                                      | object              | Which column and order to sort by                                                                                                                                                                                                                                                                                                     |
| sort                                      | column [*required*]                  | string              | Facet path for the column                                                                                                                                                                                                                                                                                                             |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| definition                                | time                                      |  <oneOf>       | Time setting for the widget.                                                                                                                                                                                                                                                                                                          |
| time                                      | Object 1                                  | object              | Wrapper for live span                                                                                                                                                                                                                                                                                                                 |
| Object 1                                  | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span                                 | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | <type=live>                               | object              | Used for arbitrary live span times, such as 17 minutes or 6 hours.                                                                                                                                                                                                                                                                    |
| <type=live>                               | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=live>                               | type [*required*]                    | enum                | Type "live" denotes a live span in the new format. Allowed enum values: `live`                                                                                                                                                                                                                                                        |
| <type=live>                               | unit [*required*]                    | enum                | Unit of the time span. Allowed enum values: `minute,hour,day,week,month,year`                                                                                                                                                                                                                                                         |
| <type=live>                               | value [*required*]                   | int64               | Value of the time span.                                                                                                                                                                                                                                                                                                               |
| time                                      | <type=fixed>                              | object              | Used for fixed span times, such as 'March 1 to March 7'.                                                                                                                                                                                                                                                                              |
| <type=fixed>                              | from [*required*]                    | int64               | Start time in milliseconds since epoch.                                                                                                                                                                                                                                                                                               |
| <type=fixed>                              | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=fixed>                              | to [*required*]                      | int64               | End time in milliseconds since epoch.                                                                                                                                                                                                                                                                                                 |
| <type=fixed>                              | type [*required*]                    | enum                | Type "fixed" denotes a fixed span. Allowed enum values: `fixed`                                                                                                                                                                                                                                                                       |
| definition                                | title                                     | string              | Title of the widget.                                                                                                                                                                                                                                                                                                                  |
| definition                                | title_align                               | enum                | How to align the text on the widget. Allowed enum values: `center,left,right`                                                                                                                                                                                                                                                         |
| definition                                | title_size                                | string              | Size of the title.                                                                                                                                                                                                                                                                                                                    |
| definition                                | type [*required*]                    | enum                | Type of the log stream widget. Allowed enum values: `log_stream`                                                                                                                                                                                                                                                                      |
| Object 6                                  | graph_size                                | enum                | The size of the graph. Allowed enum values: `xs,s,m,l,xl`                                                                                                                                                                                                                                                                             |
| Object 6                                  | time                                      | object <oneOf> | Timeframe for the notebook cell. When 'null', the notebook global time is used.                                                                                                                                                                                                                                                       |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| cells                                     | type [*required*]                    | enum                | Type of the Notebook Cell resource. Allowed enum values: `notebook_cells`                                                                                                                                                                                                                                                             |
| attributes                                | metadata                                  | object              | Metadata associated with the notebook.                                                                                                                                                                                                                                                                                                |
| metadata                                  | is_template                               | boolean             | Whether or not the notebook is a template.                                                                                                                                                                                                                                                                                            |
| metadata                                  | take_snapshots                            | boolean             | Whether or not the notebook takes snapshot image backups of the notebook's fixed-time graphs.                                                                                                                                                                                                                                         |
| metadata                                  | type                                      | enum                | Metadata type of the notebook. Allowed enum values: `postmortem,runbook,investigation,documentation,report`                                                                                                                                                                                                                           |
| attributes                                | name [*required*]                    | string              | The name of the notebook.                                                                                                                                                                                                                                                                                                             |
| attributes                                | status                                    | enum                | Publication status of the notebook. For now, always "published". Allowed enum values: `published`                                                                                                                                                                                                                                     |
| attributes                                | template_variables                        | [object]            | List of template variables for this notebook.                                                                                                                                                                                                                                                                                         |
| template_variables                        | available_values                          | [string]            | The list of values that the template variable drop-down is limited to.                                                                                                                                                                                                                                                                |
| template_variables                        | available_values_query                    |  <oneOf>       | Query used to dynamically populate the list of available values for the template variable.                                                                                                                                                                                                                                            |
| available_values_query                    | Object 1                                  | object              | Available values query for logs, RUM, or spans data sources.                                                                                                                                                                                                                                                                          |
| Object 1                                  | data_source [*required*]             | string              | The data source for the query. Must be one of `logs`, `rum`, or `spans`.                                                                                                                                                                                                                                                              |
| Object 1                                  | group_by [*required*]                | [object]            | Group-by fields for the query.                                                                                                                                                                                                                                                                                                        |
| group_by                                  | facet [*required*]                   | string              | The facet name to group by.                                                                                                                                                                                                                                                                                                           |
| Object 1                                  | search [*required*]                  | object              | Search parameters for an available values query.                                                                                                                                                                                                                                                                                      |
| search                                    | query [*required*]                   | string              | The search query string.                                                                                                                                                                                                                                                                                                              |
| available_values_query                    | Object 2                                  | object              | Available values query for the metrics data source.                                                                                                                                                                                                                                                                                   |
| Object 2                                  | data_source [*required*]             | string              | The data source for the query. Must be `metrics`.                                                                                                                                                                                                                                                                                     |
| Object 2                                  | query [*required*]                   | string              | The metrics query string.                                                                                                                                                                                                                                                                                                             |
| template_variables                        | data_source_mappings                      | object              | Mapping of data source names to template variable values.                                                                                                                                                                                                                                                                             |
| additionalProperties                      | <any-key>                                 | string              | The value for the given data source.                                                                                                                                                                                                                                                                                                  |
| template_variables                        | default                                   | string              | **DEPRECATED**: (deprecated) The default value for the template variable on notebook load. Cannot be used in conjunction with `defaults`.                                                                                                                                                                                             |
| template_variables                        | defaults                                  | [string]            | One or many default values for the template variable. Cannot be used in conjunction with `default`.                                                                                                                                                                                                                                   |
| template_variables                        | name [*required*]                    | string              | The name of the variable.                                                                                                                                                                                                                                                                                                             |
| template_variables                        | placement                                 | string              | The placement of the template variable in the notebook.                                                                                                                                                                                                                                                                               |
| template_variables                        | prefix                                    | string              | The tag prefix associated with the variable. Only tags with this prefix appear in the variable drop-down.                                                                                                                                                                                                                             |
| template_variables                        | type                                      | string              | The type of the template variable.                                                                                                                                                                                                                                                                                                    |
| attributes                                | time [*required*]                    |  <oneOf>       | Notebook global timeframe.                                                                                                                                                                                                                                                                                                            |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| data                                      | type [*required*]                    | enum                | Type of the Notebook resource. Allowed enum values: `notebooks`                                                                                                                                                                                                                                                                       |

{% /tab %}

{% tab title="Example" %}

````json
{
  "data": {
    "attributes": {
      "cells": [
        {
          "attributes": {
            "definition": {
              "text": "## Some test markdown\n\n```\nvar x, y;\nx = 5;\ny = 6;\n```",
              "type": "markdown"
            }
          },
          "type": "notebook_cells"
        },
        {
          "attributes": {
            "definition": {
              "requests": [
                {
                  "display_type": "line",
                  "q": "avg:system.load.1{*}",
                  "style": {
                    "line_type": "solid",
                    "line_width": "normal",
                    "palette": "dog_classic"
                  }
                }
              ],
              "show_legend": true,
              "type": "timeseries",
              "yaxis": {
                "scale": "linear"
              }
            },
            "graph_size": "m",
            "split_by": {
              "keys": [],
              "tags": []
            },
            "time": null
          },
          "type": "notebook_cells"
        }
      ],
      "name": "Example-Notebook",
      "status": "published",
      "time": {
        "live_span": "1h"
      }
    },
    "type": "notebooks"
  }
}
````

{% /tab %}

### Response

{% tab title="200" %}
OK
{% tab title="Model" %}
The description of a notebook response.

| Parent field                              | Field                                     | Type                | Description                                                                                                                                                                                                                                                                                                                           |
| ----------------------------------------- | ----------------------------------------- | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|                                           | data                                      | object              | The data for a notebook.                                                                                                                                                                                                                                                                                                              |
| data                                      | attributes [*required*]              | object              | The attributes of a notebook.                                                                                                                                                                                                                                                                                                         |
| attributes                                | author                                    | object              | Attributes of user object returned by the API.                                                                                                                                                                                                                                                                                        |
| author                                    | created_at                                | date-time           | Creation time of the user.                                                                                                                                                                                                                                                                                                            |
| author                                    | disabled                                  | boolean             | Whether the user is disabled.                                                                                                                                                                                                                                                                                                         |
| author                                    | email                                     | string              | Email of the user.                                                                                                                                                                                                                                                                                                                    |
| author                                    | handle                                    | string              | Handle of the user.                                                                                                                                                                                                                                                                                                                   |
| author                                    | icon                                      | string              | URL of the user's icon.                                                                                                                                                                                                                                                                                                               |
| author                                    | name                                      | string              | Name of the user.                                                                                                                                                                                                                                                                                                                     |
| author                                    | status                                    | string              | Status of the user.                                                                                                                                                                                                                                                                                                                   |
| author                                    | title                                     | string              | Title of the user.                                                                                                                                                                                                                                                                                                                    |
| author                                    | verified                                  | boolean             | Whether the user is verified.                                                                                                                                                                                                                                                                                                         |
| attributes                                | cells [*required*]                   | [object]            | List of cells to display in the notebook.                                                                                                                                                                                                                                                                                             |
| cells                                     | attributes [*required*]              |  <oneOf>       | The attributes of a notebook cell response. Valid cell types are `markdown`, `timeseries`, `toplist`, `heatmap`, `distribution`, `log_stream`. [More information on each graph visualization type.](https://docs.datadoghq.com/dashboards/widgets.md)                                                                                 |
| attributes                                | Object 1                                  | object              | The attributes of a notebook `markdown` cell.                                                                                                                                                                                                                                                                                         |
| Object 1                                  | definition [*required*]              | object              | Text in a notebook is formatted with [Markdown](https://daringfireball.net/projects/markdown/), which enables the use of headings, subheadings, links, images, lists, and code blocks.                                                                                                                                                |
| definition                                | text [*required*]                    | string              | The markdown content.                                                                                                                                                                                                                                                                                                                 |
| definition                                | type [*required*]                    | enum                | Type of the markdown cell. Allowed enum values: `markdown`                                                                                                                                                                                                                                                                            |
| attributes                                | Object 2                                  | object              | The attributes of a notebook `timeseries` cell.                                                                                                                                                                                                                                                                                       |
| Object 2                                  | definition [*required*]              | object              | The timeseries visualization allows you to display the evolution of one or more metrics, log events, or Indexed Spans over time.                                                                                                                                                                                                      |
| definition                                | custom_links                              | [object]            | List of custom links.                                                                                                                                                                                                                                                                                                                 |
| custom_links                              | is_hidden                                 | boolean             | The flag for toggling context menu link visibility.                                                                                                                                                                                                                                                                                   |
| custom_links                              | label                                     | string              | The label for the custom link URL. Keep the label short and descriptive. Use metrics and tags as variables.                                                                                                                                                                                                                           |
| custom_links                              | link                                      | string              | The URL of the custom link. URL must include `http` or `https`. A relative URL must start with `/`.                                                                                                                                                                                                                                   |
| custom_links                              | override_label                            | string              | The label ID that refers to a context menu link. Can be `logs`, `hosts`, `traces`, `profiles`, `processes`, `containers`, or `rum`.                                                                                                                                                                                                   |
| definition                                | description                               | string              | The description of the widget.                                                                                                                                                                                                                                                                                                        |
| definition                                | events                                    | [object]            | **DEPRECATED**: List of widget events. Deprecated - Use `overlay` request type instead.                                                                                                                                                                                                                                               |
| events                                    | q [*required*]                       | string              | Query definition.                                                                                                                                                                                                                                                                                                                     |
| events                                    | tags_execution                            | string              | The execution method for multi-value filters.                                                                                                                                                                                                                                                                                         |
| definition                                | legend_columns                            | [string]            | Columns displayed in the legend.                                                                                                                                                                                                                                                                                                      |
| definition                                | legend_layout                             | enum                | Layout of the legend. Allowed enum values: `auto,horizontal,vertical`                                                                                                                                                                                                                                                                 |
| definition                                | legend_size                               | string              | Available legend sizes for a widget. Should be one of "0", "2", "4", "8", "16", or "auto".                                                                                                                                                                                                                                            |
| definition                                | markers                                   | [object]            | List of markers.                                                                                                                                                                                                                                                                                                                      |
| markers                                   | display_type                              | string              | Combination of:                                                                                                                                                                                                                                                                                                                       |
| markers                                   | label                                     | string              | Label to display over the marker.                                                                                                                                                                                                                                                                                                     |
| markers                                   | time                                      | string              | Timestamp for the widget.                                                                                                                                                                                                                                                                                                             |
| markers                                   | value [*required*]                   | string              | Value to apply. Can be a single value y = 15 or a range of values 0 < y < 10. For Distribution widgets with `display_type` set to `percentile`, this should be a numeric percentile value (for example, "90" for P90).                                                                                                                |
| definition                                | requests [*required*]                | [object]            | List of timeseries widget requests.                                                                                                                                                                                                                                                                                                   |
| requests                                  | apm_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| apm_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| apm_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| apm_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | audit_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| audit_query                               | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| audit_query                               | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| audit_query                               | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| audit_query                               | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| audit_query                               | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | display_type                              | enum                | Type of display to use for the request. Allowed enum values: `area,bars,line,overlay`                                                                                                                                                                                                                                                 |
| requests                                  | event_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| event_query                               | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| event_query                               | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| event_query                               | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | formulas                                  | [object]            | List of formulas that operate on queries.                                                                                                                                                                                                                                                                                             |
| formulas                                  | alias                                     | string              | Expression alias.                                                                                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode                         | enum                | Define a display mode for the table cell. Allowed enum values: `number,bar,trend`                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode_options                 | object              | Cell display mode options for the widget formula. (only if `cell_display_mode` is set to `trend`).                                                                                                                                                                                                                                    |
| cell_display_mode_options                 | trend_type                                | enum                | Trend type for the cell display mode options. Allowed enum values: `area,line,bars`                                                                                                                                                                                                                                                   |
| cell_display_mode_options                 | y_scale                                   | enum                | Y scale for the cell display mode options. Allowed enum values: `shared,independent`                                                                                                                                                                                                                                                  |
| formulas                                  | conditional_formats                       | [object]            | List of conditional formats.                                                                                                                                                                                                                                                                                                          |
| conditional_formats                       | comparator [*required*]              | enum                | Comparator to apply. Allowed enum values: `=,>,>=,<,<=`                                                                                                                                                                                                                                                                               |
| conditional_formats                       | custom_bg_color                           | string              | Color palette to apply to the background, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | custom_fg_color                           | string              | Color palette to apply to the foreground, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | hide_value                                | boolean             | True hides values.                                                                                                                                                                                                                                                                                                                    |
| conditional_formats                       | image_url                                 | string              | Displays an image as the background.                                                                                                                                                                                                                                                                                                  |
| conditional_formats                       | metric                                    | string              | Metric from the request to correlate this conditional format with.                                                                                                                                                                                                                                                                    |
| conditional_formats                       | palette [*required*]                 | enum                | Color palette to apply. Allowed enum values: `blue,custom_bg,custom_image,custom_text,gray_on_white,grey,green,orange,red,red_on_white`                                                                                                                                                                                               |
| conditional_formats                       | timeframe                                 | string              | Defines the displayed timeframe.                                                                                                                                                                                                                                                                                                      |
| conditional_formats                       | value [*required*]                   | double              | Value for the comparator.                                                                                                                                                                                                                                                                                                             |
| formulas                                  | formula [*required*]                 | string              | String expression built from queries, formulas, and functions.                                                                                                                                                                                                                                                                        |
| formulas                                  | limit                                     | object              | Options for limiting results returned.                                                                                                                                                                                                                                                                                                |
| limit                                     | count                                     | int64               | Number of results to return.                                                                                                                                                                                                                                                                                                          |
| limit                                     | order                                     | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| formulas                                  | number_format                             | object              | Number format options for the widget.                                                                                                                                                                                                                                                                                                 |
| number_format                             | unit                                      |  <oneOf>       | Number format unit.                                                                                                                                                                                                                                                                                                                   |
| unit                                      | <type=canonical_unit>                     | object              | Canonical unit.                                                                                                                                                                                                                                                                                                                       |
| unit                                      | <type=custom_unit_label>                  | object              | Custom unit.                                                                                                                                                                                                                                                                                                                          |
| number_format                             | unit_scale                                | object              | The definition of `NumberFormatUnitScale` object.                                                                                                                                                                                                                                                                                     |
| unit_scale                                | type                                      | enum                | The type of unit scale. Allowed enum values: `canonical_unit`                                                                                                                                                                                                                                                                         |
| unit_scale                                | unit_name                                 | string              | The name of the unit.                                                                                                                                                                                                                                                                                                                 |
| formulas                                  | style                                     | object              | Styling options for widget formulas.                                                                                                                                                                                                                                                                                                  |
| style                                     | palette                                   | string              | The color palette used to display the formula. A guide to the available color palettes can be found at [https://docs.datadoghq.com/dashboards/guide/widget_colors](https://docs.datadoghq.com/dashboards/guide/widget_colors.md)                                                                                                      |
| style                                     | palette_index                             | int64               | Index specifying which color to use within the palette.                                                                                                                                                                                                                                                                               |
| requests                                  | log_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| log_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| log_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| log_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | metadata                                  | [object]            | Used to define expression aliases.                                                                                                                                                                                                                                                                                                    |
| metadata                                  | alias_name                                | string              | Expression alias.                                                                                                                                                                                                                                                                                                                     |
| metadata                                  | expression [*required*]              | string              | Expression name.                                                                                                                                                                                                                                                                                                                      |
| requests                                  | network_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| network_query                             | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| network_query                             | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| network_query                             | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | on_right_yaxis                            | boolean             | Whether or not to display a second y-axis on the right.                                                                                                                                                                                                                                                                               |
| requests                                  | process_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| process_query                             | filter_by                                 | [string]            | List of processes.                                                                                                                                                                                                                                                                                                                    |
| process_query                             | limit                                     | int64               | Max number of items in the filter list.                                                                                                                                                                                                                                                                                               |
| process_query                             | metric [*required*]                  | string              | Your chosen metric.                                                                                                                                                                                                                                                                                                                   |
| process_query                             | search_by                                 | string              | Your chosen search term.                                                                                                                                                                                                                                                                                                              |
| requests                                  | profile_metrics_query                     | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| profile_metrics_query                     | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| profile_metrics_query                     | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | q                                         | string              | **DEPRECATED**: Widget query. Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                      |
| requests                                  | queries                                   | [ <oneOf>]     | List of queries that can be returned directly or used in formulas.                                                                                                                                                                                                                                                                    |
| queries                                   | <data_source=metrics>                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| <data_source=metrics>                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=metrics>                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| <data_source=metrics>                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| <data_source=metrics>                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| queries                                   | Object 2                                  | object              | A formula and functions events query.                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | compute [*required*]                 | object              | Compute options.                                                                                                                                                                                                                                                                                                                      |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | int64               | A time interval in milliseconds.                                                                                                                                                                                                                                                                                                      |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| Object 2                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 2                                  | data_source [*required*]             | enum                | Data source for event platform-based queries. Allowed enum values: `logs,spans,network,rum,security_signals,profiles,audit,events,ci_tests,ci_pipelines`                                                                                                                                                                              |
| Object 2                                  | group_by                                  |  <oneOf>       | Group by configuration for a formula and functions events query. Accepts either a list of facet objects or a flat object that specifies a list of facet fields.                                                                                                                                                                       |
| group_by                                  | Object 1                                  | [object]            | List of objects used to group by.                                                                                                                                                                                                                                                                                                     |
| group_by                                  | Object 2                                  | object              | Flat group by configuration using multiple event facet fields.                                                                                                                                                                                                                                                                        |
| Object 2                                  | indexes                                   | [string]            | An array of index names to query in the stream. Omit or use `[]` to query all indexes at once.                                                                                                                                                                                                                                        |
| Object 2                                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| Object 2                                  | search                                    | object              | Search options.                                                                                                                                                                                                                                                                                                                       |
| search                                    | query [*required*]                   | string              | Events search string.                                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | storage                                   | string              | Option for storage location. Feature in Private Beta.                                                                                                                                                                                                                                                                                 |
| queries                                   | Object 3                                  | object              | Process query using formulas and functions.                                                                                                                                                                                                                                                                                           |
| Object 3                                  | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| Object 3                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 3                                  | data_source [*required*]             | enum                | Data sources that rely on the process backend. Allowed enum values: `process,container`                                                                                                                                                                                                                                               |
| Object 3                                  | is_normalized_cpu                         | boolean             | Whether to normalize the CPU percentages.                                                                                                                                                                                                                                                                                             |
| Object 3                                  | limit                                     | int64               | Number of hits to return.                                                                                                                                                                                                                                                                                                             |
| Object 3                                  | metric [*required*]                  | string              | Process metric name.                                                                                                                                                                                                                                                                                                                  |
| Object 3                                  | name [*required*]                    | string              | Name of query for use in formulas.                                                                                                                                                                                                                                                                                                    |
| Object 3                                  | sort                                      | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| Object 3                                  | tag_filters                               | [string]            | An array of tags to filter by.                                                                                                                                                                                                                                                                                                        |
| Object 3                                  | text_filter                               | string              | Text to use as filter.                                                                                                                                                                                                                                                                                                                |
| queries                                   | <data_source=apm_dependency_stats>        | object              | A formula and functions APM dependency stats query.                                                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | data_source [*required*]             | enum                | Data source for APM dependency stats queries. Allowed enum values: `apm_dependency_stats`                                                                                                                                                                                                                                             |
| <data_source=apm_dependency_stats>        | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_dependency_stats>        | is_upstream                               | boolean             | Determines whether stats for upstream or downstream dependencies should be queried.                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | name [*required*]                    | string              | Name of query to use in formulas.                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_dependency_stats>        | operation_name [*required*]          | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | primary_tag_name                          | string              | The name of the second primary tag used within APM; required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog). |
| <data_source=apm_dependency_stats>        | primary_tag_value                         | string              | Filter APM data by the second primary tag. `primary_tag_name` must also be specified.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | resource_name [*required*]           | string              | APM resource.                                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | service [*required*]                 | string              | APM service.                                                                                                                                                                                                                                                                                                                          |
| <data_source=apm_dependency_stats>        | stat [*required*]                    | enum                | APM statistic. Allowed enum values: `avg_duration,avg_root_duration,avg_spans_per_trace,error_rate,pct_exec_time,pct_of_traces,total_traces_count`                                                                                                                                                                                    |
| queries                                   | <data_source=apm_resource_stats>          | object              | **DEPRECATED**: APM resource stats query using formulas and functions. Deprecated - Use `apm_metrics` query type instead.                                                                                                                                                                                                             |
| <data_source=apm_resource_stats>          | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | data_source [*required*]             | enum                | Data source for APM resource stats queries. Allowed enum values: `apm_resource_stats`                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_resource_stats>          | group_by                                  | [string]            | Array of fields to group results by.                                                                                                                                                                                                                                                                                                  |
| <data_source=apm_resource_stats>          | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_resource_stats>          | operation_name                            | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_resource_stats>          | primary_tag_name                          | string              | Name of the second primary tag used within APM. Required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog)      |
| <data_source=apm_resource_stats>          | primary_tag_value                         | string              | Value of the second primary tag by which to filter APM data. `primary_tag_name` must also be specified.                                                                                                                                                                                                                               |
| <data_source=apm_resource_stats>          | resource_name                             | string              | APM resource name.                                                                                                                                                                                                                                                                                                                    |
| <data_source=apm_resource_stats>          | service [*required*]                 | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_resource_stats>          | stat [*required*]                    | enum                | APM resource stat name. Allowed enum values: `errors,error_rate,hits,latency_avg,latency_distribution,latency_max,latency_p50,latency_p75,latency_p90,latency_p95`                                                                                                                                                                    |
| queries                                   | <data_source=apm_metrics>                 | object              | A formula and functions APM metrics query.                                                                                                                                                                                                                                                                                            |
| <data_source=apm_metrics>                 | data_source [*required*]             | enum                | Data source for APM metrics queries. Allowed enum values: `apm_metrics`                                                                                                                                                                                                                                                               |
| <data_source=apm_metrics>                 | group_by                                  | [string]            | Optional fields to group the query results by.                                                                                                                                                                                                                                                                                        |
| <data_source=apm_metrics>                 | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_metrics>                 | operation_mode                            | string              | Optional operation mode to aggregate across operation names.                                                                                                                                                                                                                                                                          |
| <data_source=apm_metrics>                 | operation_name                            | string              | Name of operation on service. If not provided, the primary operation name is used.                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | peer_tags                                 | [string]            | Tags to query for a specific downstream entity (peer.service, peer.db_instance, peer.s3, peer.s3.bucket, etc.).                                                                                                                                                                                                                       |
| <data_source=apm_metrics>                 | query_filter                              | string              | Additional filters for the query using metrics query syntax (e.g., env, primary_tag).                                                                                                                                                                                                                                                 |
| <data_source=apm_metrics>                 | resource_hash                             | string              | The hash of a specific resource to filter by.                                                                                                                                                                                                                                                                                         |
| <data_source=apm_metrics>                 | resource_name                             | string              | The full name of a specific resource to filter by.                                                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | service                                   | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_metrics>                 | span_kind                                 | enum                | Describes the relationship between the span, its parents, and its children in a trace. Allowed enum values: `consumer,server,client,producer,internal`                                                                                                                                                                                |
| <data_source=apm_metrics>                 | stat [*required*]                    | enum                | APM metric stat name. Allowed enum values: `errors,error_rate,errors_per_second,latency_avg,latency_max,latency_p50,latency_p75,latency_p90,latency_p95,latency_p99`                                                                                                                                                                  |
| queries                                   | <data_source=slo>                         | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | additional_query_filters                  | string              | Additional filters applied to the SLO query.                                                                                                                                                                                                                                                                                          |
| <data_source=slo>                         | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=slo>                         | data_source [*required*]             | enum                | Data source for SLO measures queries. Allowed enum values: `slo`                                                                                                                                                                                                                                                                      |
| <data_source=slo>                         | group_mode                                | enum                | Group mode to query measures. Allowed enum values: `overall,components`                                                                                                                                                                                                                                                               |
| <data_source=slo>                         | measure [*required*]                 | enum                | SLO measures queries. Allowed enum values: `good_events,bad_events,good_minutes,bad_minutes,slo_status,error_budget_remaining,burn_rate,error_budget_burndown`                                                                                                                                                                        |
| <data_source=slo>                         | name                                      | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | slo_id [*required*]                  | string              | ID of an SLO to query measures.                                                                                                                                                                                                                                                                                                       |
| <data_source=slo>                         | slo_query_type                            | enum                | Name of the query for use in formulas. Allowed enum values: `metric,monitor,time_slice`                                                                                                                                                                                                                                               |
| queries                                   | <data_source=cloud_cost>                  | object              | A formula and functions Cloud Cost query.                                                                                                                                                                                                                                                                                             |
| <data_source=cloud_cost>                  | aggregator                                | enum                | Aggregator used for the request. Allowed enum values: `avg,last,max,min,sum,percentile`                                                                                                                                                                                                                                               |
| <data_source=cloud_cost>                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | data_source [*required*]             | enum                | Data source for Cloud Cost queries. Allowed enum values: `cloud_cost`                                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=cloud_cost>                  | query [*required*]                   | string              | Query for Cloud Cost data.                                                                                                                                                                                                                                                                                                            |
| queries                                   | <data_source=product_analytics_extended>  | object              | A formula and functions Product Analytics Extended query for advanced analytics features.                                                                                                                                                                                                                                             |
| <data_source=product_analytics_extended>  | audience_filters                          | object              | Product Analytics/RUM audience filters.                                                                                                                                                                                                                                                                                               |
| audience_filters                          | accounts                                  | [object]            |
| audience_filters                          | filter_condition                          | string              | An optional filter condition applied to the audience subquery.                                                                                                                                                                                                                                                                        |
| audience_filters                          | segments                                  | [object]            |
| audience_filters                          | users                                     | [object]            |
| <data_source=product_analytics_extended>  | compute [*required*]                 | object              | Compute configuration for Product Analytics Extended queries.                                                                                                                                                                                                                                                                         |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Fixed-width time bucket interval in milliseconds for time series queries. Mutually exclusive with `rollup`.                                                                                                                                                                                                                           |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| compute                                   | name                                      | string              | Name of the compute for use in formulas.                                                                                                                                                                                                                                                                                              |
| compute                                   | rollup                                    | object              | Calendar-aligned time bucket for time series queries (for example, day, week, or month boundaries). Mutually exclusive with `interval`.                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | data_source [*required*]             | enum                | Data source for Product Analytics Extended queries. Allowed enum values: `product_analytics_extended`                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | indexes                                   | [string]            | Event indexes to query.                                                                                                                                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_extended>  | query [*required*]                   | object              | Base query for Product Analytics.                                                                                                                                                                                                                                                                                                     |
| query                                     | data_source [*required*]             | enum                | Data source for Product Analytics event queries. Allowed enum values: `product_analytics`                                                                                                                                                                                                                                             |
| query                                     | search [*required*]                  | object              | Search configuration for Product Analytics event query.                                                                                                                                                                                                                                                                               |
| queries                                   | <data_source=product_analytics_journey>   | object              | A formula and functions User Journey query for defining funnel, timeseries, and scalar visualizations over journey data.                                                                                                                                                                                                              |
| <data_source=product_analytics_journey>   | compute [*required*]                 | object              | Compute configuration for User Journey formula queries.                                                                                                                                                                                                                                                                               |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Time bucket interval in milliseconds for time series queries.                                                                                                                                                                                                                                                                         |
| compute                                   | metric                                    | enum                | Metric for User Journey formula compute. `__dd.conversion` and `__dd.conversion_rate` accept `count` and `cardinality` as aggregations. `__dd.time_to_convert` accepts `avg`, `median`, `pc75`, `pc95`, `pc98`, `pc99`, `min`, and `max`. Allowed enum values: `__dd.conversion,__dd.conversion_rate,__dd.time_to_convert`            |
| compute                                   | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | data_source [*required*]             | enum                | Data source for user journey funnel queries. Allowed enum values: `product_analytics_journey`                                                                                                                                                                                                                                         |
| <data_source=product_analytics_journey>   | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_journey>   | search [*required*]                  | object              | User journey search configuration.                                                                                                                                                                                                                                                                                                    |
| search                                    | expression [*required*]              | string              | Expression string.                                                                                                                                                                                                                                                                                                                    |
| search                                    | filters                                   | object              | Filters for user journey search.                                                                                                                                                                                                                                                                                                      |
| search                                    | join_keys                                 | object              | Join keys for user journey queries.                                                                                                                                                                                                                                                                                                   |
| search                                    | node_objects [*required*]            | object              | Node objects mapping.                                                                                                                                                                                                                                                                                                                 |
| search                                    | step_aliases                              | object              | Step aliases mapping.                                                                                                                                                                                                                                                                                                                 |
| queries                                   | <data_source=product_analytics_retention> | object              | A formula and functions Retention query for defining timeseries and scalar visualizations.                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | compute [*required*]                 | object              | Compute configuration for retention queries.                                                                                                                                                                                                                                                                                          |
| compute                                   | aggregation [*required*]             |  <oneOf>       | The type of aggregation that can be performed on events-based queries.                                                                                                                                                                                                                                                                |
| compute                                   | metric [*required*]                  | enum                | Metric for retention compute. Allowed enum values: `__dd.retention,__dd.retention_rate`                                                                                                                                                                                                                                               |
| <data_source=product_analytics_retention> | data_source [*required*]             | enum                | Data source for retention queries. Allowed enum values: `product_analytics_retention`                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_retention> | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet to group by.                                                                                                                                                                                                                                                                                                                    |
| group_by                                  | limit                                     | int64               | Maximum number of groups.                                                                                                                                                                                                                                                                                                             |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude missing values.                                                                                                                                                                                                                                                                                                    |
| group_by                                  | sort                                      | object              | Sort configuration for retention group by.                                                                                                                                                                                                                                                                                            |
| group_by                                  | source                                    | string              | Source field.                                                                                                                                                                                                                                                                                                                         |
| group_by                                  | target [*required*]                  | enum                | Target for retention group by. Allowed enum values: `cohort,return_period`                                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_retention> | search [*required*]                  | object              | Search configuration for retention queries.                                                                                                                                                                                                                                                                                           |
| search                                    | cohort_criteria [*required*]         | object              | Cohort criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| search                                    | filters                                   | object              | Filters for retention queries.                                                                                                                                                                                                                                                                                                        |
| search                                    | retention_entity [*required*]        | enum                | Entity to track for retention. Allowed enum values: `@usr.id,@account.id`                                                                                                                                                                                                                                                             |
| search                                    | return_condition [*required*]        | enum                | Condition for counting user return. Allowed enum values: `conversion_on,conversion_on_or_after`                                                                                                                                                                                                                                       |
| search                                    | return_criteria                           | object              | Return criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| requests                                  | response_format                           | enum                | Timeseries, scalar, or event list response. Event list response formats are supported by Geomap widgets. Allowed enum values: `timeseries,scalar,event_list`                                                                                                                                                                          |
| requests                                  | rum_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| rum_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| rum_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| rum_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | security_query                            | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| security_query                            | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| security_query                            | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| security_query                            | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | style                                     | object              | Define request widget style for timeseries widgets.                                                                                                                                                                                                                                                                                   |
| style                                     | has_value_labels                          | boolean             | If true, the value is displayed as a label relative to the data point.                                                                                                                                                                                                                                                                |
| style                                     | line_type                                 | enum                | Type of lines displayed. Allowed enum values: `dashed,dotted,solid`                                                                                                                                                                                                                                                                   |
| style                                     | line_width                                | enum                | Width of line displayed. Allowed enum values: `normal,thick,thin`                                                                                                                                                                                                                                                                     |
| style                                     | order_by                                  | enum                | How to order series in timeseries visualizations.                                                                                                                                                                                                                                                                                     |
| style                                     | palette                                   | string              | Color palette to apply to the widget.                                                                                                                                                                                                                                                                                                 |
| definition                                | right_yaxis                               | object              | Axis controls for the widget.                                                                                                                                                                                                                                                                                                         |
| right_yaxis                               | include_zero                              | boolean             | Set to `true` to include zero.                                                                                                                                                                                                                                                                                                        |
| right_yaxis                               | label                                     | string              | The label of the axis to display on the graph. Only usable on Scatterplot Widgets.                                                                                                                                                                                                                                                    |
| right_yaxis                               | max                                       | string              | Specifies maximum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| right_yaxis                               | min                                       | string              | Specifies minimum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| right_yaxis                               | scale                                     | string              | Specifies the scale type. Possible values are `linear`, `log`, `sqrt`, and `pow##` (for example `pow2` or `pow0.5`).                                                                                                                                                                                                                  |
| definition                                | show_legend                               | boolean             | (screenboard only) Show the legend for this widget.                                                                                                                                                                                                                                                                                   |
| definition                                | time                                      |  <oneOf>       | Time setting for the widget.                                                                                                                                                                                                                                                                                                          |
| time                                      | Object 1                                  | object              | Wrapper for live span                                                                                                                                                                                                                                                                                                                 |
| Object 1                                  | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span                                 | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | <type=live>                               | object              | Used for arbitrary live span times, such as 17 minutes or 6 hours.                                                                                                                                                                                                                                                                    |
| <type=live>                               | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=live>                               | type [*required*]                    | enum                | Type "live" denotes a live span in the new format. Allowed enum values: `live`                                                                                                                                                                                                                                                        |
| <type=live>                               | unit [*required*]                    | enum                | Unit of the time span. Allowed enum values: `minute,hour,day,week,month,year`                                                                                                                                                                                                                                                         |
| <type=live>                               | value [*required*]                   | int64               | Value of the time span.                                                                                                                                                                                                                                                                                                               |
| time                                      | <type=fixed>                              | object              | Used for fixed span times, such as 'March 1 to March 7'.                                                                                                                                                                                                                                                                              |
| <type=fixed>                              | from [*required*]                    | int64               | Start time in milliseconds since epoch.                                                                                                                                                                                                                                                                                               |
| <type=fixed>                              | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=fixed>                              | to [*required*]                      | int64               | End time in milliseconds since epoch.                                                                                                                                                                                                                                                                                                 |
| <type=fixed>                              | type [*required*]                    | enum                | Type "fixed" denotes a fixed span. Allowed enum values: `fixed`                                                                                                                                                                                                                                                                       |
| definition                                | title                                     | string              | Title of your widget.                                                                                                                                                                                                                                                                                                                 |
| definition                                | title_align                               | enum                | How to align the text on the widget. Allowed enum values: `center,left,right`                                                                                                                                                                                                                                                         |
| definition                                | title_size                                | string              | Size of the title.                                                                                                                                                                                                                                                                                                                    |
| definition                                | type [*required*]                    | enum                | Type of the timeseries widget. Allowed enum values: `timeseries`                                                                                                                                                                                                                                                                      |
| definition                                | yaxis                                     | object              | Axis controls for the widget.                                                                                                                                                                                                                                                                                                         |
| yaxis                                     | include_zero                              | boolean             | Set to `true` to include zero.                                                                                                                                                                                                                                                                                                        |
| yaxis                                     | label                                     | string              | The label of the axis to display on the graph. Only usable on Scatterplot Widgets.                                                                                                                                                                                                                                                    |
| yaxis                                     | max                                       | string              | Specifies maximum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| yaxis                                     | min                                       | string              | Specifies minimum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| yaxis                                     | scale                                     | string              | Specifies the scale type. Possible values are `linear`, `log`, `sqrt`, and `pow##` (for example `pow2` or `pow0.5`).                                                                                                                                                                                                                  |
| Object 2                                  | graph_size                                | enum                | The size of the graph. Allowed enum values: `xs,s,m,l,xl`                                                                                                                                                                                                                                                                             |
| Object 2                                  | split_by                                  | object              | Object describing how to split the graph to display multiple visualizations per request.                                                                                                                                                                                                                                              |
| split_by                                  | keys [*required*]                    | [string]            | Keys to split on.                                                                                                                                                                                                                                                                                                                     |
| split_by                                  | tags [*required*]                    | [string]            | Tags to split on.                                                                                                                                                                                                                                                                                                                     |
| Object 2                                  | time                                      | object <oneOf> | Timeframe for the notebook cell. When 'null', the notebook global time is used.                                                                                                                                                                                                                                                       |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| attributes                                | Object 3                                  | object              | The attributes of a notebook `toplist` cell.                                                                                                                                                                                                                                                                                          |
| Object 3                                  | definition [*required*]              | object              | The top list visualization enables you to display a list of Tag value like hostname or service with the most or least of any metric value, such as highest consumers of CPU, hosts with the least disk space, etc.                                                                                                                    |
| definition                                | custom_links                              | [object]            | List of custom links.                                                                                                                                                                                                                                                                                                                 |
| custom_links                              | is_hidden                                 | boolean             | The flag for toggling context menu link visibility.                                                                                                                                                                                                                                                                                   |
| custom_links                              | label                                     | string              | The label for the custom link URL. Keep the label short and descriptive. Use metrics and tags as variables.                                                                                                                                                                                                                           |
| custom_links                              | link                                      | string              | The URL of the custom link. URL must include `http` or `https`. A relative URL must start with `/`.                                                                                                                                                                                                                                   |
| custom_links                              | override_label                            | string              | The label ID that refers to a context menu link. Can be `logs`, `hosts`, `traces`, `profiles`, `processes`, `containers`, or `rum`.                                                                                                                                                                                                   |
| definition                                | description                               | string              | The description of the widget.                                                                                                                                                                                                                                                                                                        |
| definition                                | requests [*required*]                | [object]            | List of top list widget requests.                                                                                                                                                                                                                                                                                                     |
| requests                                  | apm_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| apm_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| apm_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| apm_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | audit_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| audit_query                               | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| audit_query                               | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| audit_query                               | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| audit_query                               | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| audit_query                               | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | conditional_formats                       | [object]            | List of conditional formats.                                                                                                                                                                                                                                                                                                          |
| conditional_formats                       | comparator [*required*]              | enum                | Comparator to apply. Allowed enum values: `=,>,>=,<,<=`                                                                                                                                                                                                                                                                               |
| conditional_formats                       | custom_bg_color                           | string              | Color palette to apply to the background, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | custom_fg_color                           | string              | Color palette to apply to the foreground, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | hide_value                                | boolean             | True hides values.                                                                                                                                                                                                                                                                                                                    |
| conditional_formats                       | image_url                                 | string              | Displays an image as the background.                                                                                                                                                                                                                                                                                                  |
| conditional_formats                       | metric                                    | string              | Metric from the request to correlate this conditional format with.                                                                                                                                                                                                                                                                    |
| conditional_formats                       | palette [*required*]                 | enum                | Color palette to apply. Allowed enum values: `blue,custom_bg,custom_image,custom_text,gray_on_white,grey,green,orange,red,red_on_white`                                                                                                                                                                                               |
| conditional_formats                       | timeframe                                 | string              | Defines the displayed timeframe.                                                                                                                                                                                                                                                                                                      |
| conditional_formats                       | value [*required*]                   | double              | Value for the comparator.                                                                                                                                                                                                                                                                                                             |
| requests                                  | event_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| event_query                               | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| event_query                               | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| event_query                               | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | formulas                                  | [object]            | List of formulas that operate on queries.                                                                                                                                                                                                                                                                                             |
| formulas                                  | alias                                     | string              | Expression alias.                                                                                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode                         | enum                | Define a display mode for the table cell. Allowed enum values: `number,bar,trend`                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode_options                 | object              | Cell display mode options for the widget formula. (only if `cell_display_mode` is set to `trend`).                                                                                                                                                                                                                                    |
| cell_display_mode_options                 | trend_type                                | enum                | Trend type for the cell display mode options. Allowed enum values: `area,line,bars`                                                                                                                                                                                                                                                   |
| cell_display_mode_options                 | y_scale                                   | enum                | Y scale for the cell display mode options. Allowed enum values: `shared,independent`                                                                                                                                                                                                                                                  |
| formulas                                  | conditional_formats                       | [object]            | List of conditional formats.                                                                                                                                                                                                                                                                                                          |
| conditional_formats                       | comparator [*required*]              | enum                | Comparator to apply. Allowed enum values: `=,>,>=,<,<=`                                                                                                                                                                                                                                                                               |
| conditional_formats                       | custom_bg_color                           | string              | Color palette to apply to the background, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | custom_fg_color                           | string              | Color palette to apply to the foreground, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | hide_value                                | boolean             | True hides values.                                                                                                                                                                                                                                                                                                                    |
| conditional_formats                       | image_url                                 | string              | Displays an image as the background.                                                                                                                                                                                                                                                                                                  |
| conditional_formats                       | metric                                    | string              | Metric from the request to correlate this conditional format with.                                                                                                                                                                                                                                                                    |
| conditional_formats                       | palette [*required*]                 | enum                | Color palette to apply. Allowed enum values: `blue,custom_bg,custom_image,custom_text,gray_on_white,grey,green,orange,red,red_on_white`                                                                                                                                                                                               |
| conditional_formats                       | timeframe                                 | string              | Defines the displayed timeframe.                                                                                                                                                                                                                                                                                                      |
| conditional_formats                       | value [*required*]                   | double              | Value for the comparator.                                                                                                                                                                                                                                                                                                             |
| formulas                                  | formula [*required*]                 | string              | String expression built from queries, formulas, and functions.                                                                                                                                                                                                                                                                        |
| formulas                                  | limit                                     | object              | Options for limiting results returned.                                                                                                                                                                                                                                                                                                |
| limit                                     | count                                     | int64               | Number of results to return.                                                                                                                                                                                                                                                                                                          |
| limit                                     | order                                     | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| formulas                                  | number_format                             | object              | Number format options for the widget.                                                                                                                                                                                                                                                                                                 |
| number_format                             | unit                                      |  <oneOf>       | Number format unit.                                                                                                                                                                                                                                                                                                                   |
| unit                                      | <type=canonical_unit>                     | object              | Canonical unit.                                                                                                                                                                                                                                                                                                                       |
| unit                                      | <type=custom_unit_label>                  | object              | Custom unit.                                                                                                                                                                                                                                                                                                                          |
| number_format                             | unit_scale                                | object              | The definition of `NumberFormatUnitScale` object.                                                                                                                                                                                                                                                                                     |
| unit_scale                                | type                                      | enum                | The type of unit scale. Allowed enum values: `canonical_unit`                                                                                                                                                                                                                                                                         |
| unit_scale                                | unit_name                                 | string              | The name of the unit.                                                                                                                                                                                                                                                                                                                 |
| formulas                                  | style                                     | object              | Styling options for widget formulas.                                                                                                                                                                                                                                                                                                  |
| style                                     | palette                                   | string              | The color palette used to display the formula. A guide to the available color palettes can be found at [https://docs.datadoghq.com/dashboards/guide/widget_colors](https://docs.datadoghq.com/dashboards/guide/widget_colors.md)                                                                                                      |
| style                                     | palette_index                             | int64               | Index specifying which color to use within the palette.                                                                                                                                                                                                                                                                               |
| requests                                  | log_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| log_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| log_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| log_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | network_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| network_query                             | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| network_query                             | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| network_query                             | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | process_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| process_query                             | filter_by                                 | [string]            | List of processes.                                                                                                                                                                                                                                                                                                                    |
| process_query                             | limit                                     | int64               | Max number of items in the filter list.                                                                                                                                                                                                                                                                                               |
| process_query                             | metric [*required*]                  | string              | Your chosen metric.                                                                                                                                                                                                                                                                                                                   |
| process_query                             | search_by                                 | string              | Your chosen search term.                                                                                                                                                                                                                                                                                                              |
| requests                                  | profile_metrics_query                     | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| profile_metrics_query                     | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| profile_metrics_query                     | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | q                                         | string              | **DEPRECATED**: Widget query. Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                      |
| requests                                  | queries                                   | [ <oneOf>]     | List of queries that can be returned directly or used in formulas.                                                                                                                                                                                                                                                                    |
| queries                                   | <data_source=metrics>                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| <data_source=metrics>                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=metrics>                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| <data_source=metrics>                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| <data_source=metrics>                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| queries                                   | Object 2                                  | object              | A formula and functions events query.                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | compute [*required*]                 | object              | Compute options.                                                                                                                                                                                                                                                                                                                      |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | int64               | A time interval in milliseconds.                                                                                                                                                                                                                                                                                                      |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| Object 2                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 2                                  | data_source [*required*]             | enum                | Data source for event platform-based queries. Allowed enum values: `logs,spans,network,rum,security_signals,profiles,audit,events,ci_tests,ci_pipelines`                                                                                                                                                                              |
| Object 2                                  | group_by                                  |  <oneOf>       | Group by configuration for a formula and functions events query. Accepts either a list of facet objects or a flat object that specifies a list of facet fields.                                                                                                                                                                       |
| group_by                                  | Object 1                                  | [object]            | List of objects used to group by.                                                                                                                                                                                                                                                                                                     |
| group_by                                  | Object 2                                  | object              | Flat group by configuration using multiple event facet fields.                                                                                                                                                                                                                                                                        |
| Object 2                                  | indexes                                   | [string]            | An array of index names to query in the stream. Omit or use `[]` to query all indexes at once.                                                                                                                                                                                                                                        |
| Object 2                                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| Object 2                                  | search                                    | object              | Search options.                                                                                                                                                                                                                                                                                                                       |
| search                                    | query [*required*]                   | string              | Events search string.                                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | storage                                   | string              | Option for storage location. Feature in Private Beta.                                                                                                                                                                                                                                                                                 |
| queries                                   | Object 3                                  | object              | Process query using formulas and functions.                                                                                                                                                                                                                                                                                           |
| Object 3                                  | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| Object 3                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 3                                  | data_source [*required*]             | enum                | Data sources that rely on the process backend. Allowed enum values: `process,container`                                                                                                                                                                                                                                               |
| Object 3                                  | is_normalized_cpu                         | boolean             | Whether to normalize the CPU percentages.                                                                                                                                                                                                                                                                                             |
| Object 3                                  | limit                                     | int64               | Number of hits to return.                                                                                                                                                                                                                                                                                                             |
| Object 3                                  | metric [*required*]                  | string              | Process metric name.                                                                                                                                                                                                                                                                                                                  |
| Object 3                                  | name [*required*]                    | string              | Name of query for use in formulas.                                                                                                                                                                                                                                                                                                    |
| Object 3                                  | sort                                      | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| Object 3                                  | tag_filters                               | [string]            | An array of tags to filter by.                                                                                                                                                                                                                                                                                                        |
| Object 3                                  | text_filter                               | string              | Text to use as filter.                                                                                                                                                                                                                                                                                                                |
| queries                                   | <data_source=apm_dependency_stats>        | object              | A formula and functions APM dependency stats query.                                                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | data_source [*required*]             | enum                | Data source for APM dependency stats queries. Allowed enum values: `apm_dependency_stats`                                                                                                                                                                                                                                             |
| <data_source=apm_dependency_stats>        | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_dependency_stats>        | is_upstream                               | boolean             | Determines whether stats for upstream or downstream dependencies should be queried.                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | name [*required*]                    | string              | Name of query to use in formulas.                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_dependency_stats>        | operation_name [*required*]          | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | primary_tag_name                          | string              | The name of the second primary tag used within APM; required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog). |
| <data_source=apm_dependency_stats>        | primary_tag_value                         | string              | Filter APM data by the second primary tag. `primary_tag_name` must also be specified.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | resource_name [*required*]           | string              | APM resource.                                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | service [*required*]                 | string              | APM service.                                                                                                                                                                                                                                                                                                                          |
| <data_source=apm_dependency_stats>        | stat [*required*]                    | enum                | APM statistic. Allowed enum values: `avg_duration,avg_root_duration,avg_spans_per_trace,error_rate,pct_exec_time,pct_of_traces,total_traces_count`                                                                                                                                                                                    |
| queries                                   | <data_source=apm_resource_stats>          | object              | **DEPRECATED**: APM resource stats query using formulas and functions. Deprecated - Use `apm_metrics` query type instead.                                                                                                                                                                                                             |
| <data_source=apm_resource_stats>          | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | data_source [*required*]             | enum                | Data source for APM resource stats queries. Allowed enum values: `apm_resource_stats`                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_resource_stats>          | group_by                                  | [string]            | Array of fields to group results by.                                                                                                                                                                                                                                                                                                  |
| <data_source=apm_resource_stats>          | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_resource_stats>          | operation_name                            | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_resource_stats>          | primary_tag_name                          | string              | Name of the second primary tag used within APM. Required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog)      |
| <data_source=apm_resource_stats>          | primary_tag_value                         | string              | Value of the second primary tag by which to filter APM data. `primary_tag_name` must also be specified.                                                                                                                                                                                                                               |
| <data_source=apm_resource_stats>          | resource_name                             | string              | APM resource name.                                                                                                                                                                                                                                                                                                                    |
| <data_source=apm_resource_stats>          | service [*required*]                 | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_resource_stats>          | stat [*required*]                    | enum                | APM resource stat name. Allowed enum values: `errors,error_rate,hits,latency_avg,latency_distribution,latency_max,latency_p50,latency_p75,latency_p90,latency_p95`                                                                                                                                                                    |
| queries                                   | <data_source=apm_metrics>                 | object              | A formula and functions APM metrics query.                                                                                                                                                                                                                                                                                            |
| <data_source=apm_metrics>                 | data_source [*required*]             | enum                | Data source for APM metrics queries. Allowed enum values: `apm_metrics`                                                                                                                                                                                                                                                               |
| <data_source=apm_metrics>                 | group_by                                  | [string]            | Optional fields to group the query results by.                                                                                                                                                                                                                                                                                        |
| <data_source=apm_metrics>                 | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_metrics>                 | operation_mode                            | string              | Optional operation mode to aggregate across operation names.                                                                                                                                                                                                                                                                          |
| <data_source=apm_metrics>                 | operation_name                            | string              | Name of operation on service. If not provided, the primary operation name is used.                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | peer_tags                                 | [string]            | Tags to query for a specific downstream entity (peer.service, peer.db_instance, peer.s3, peer.s3.bucket, etc.).                                                                                                                                                                                                                       |
| <data_source=apm_metrics>                 | query_filter                              | string              | Additional filters for the query using metrics query syntax (e.g., env, primary_tag).                                                                                                                                                                                                                                                 |
| <data_source=apm_metrics>                 | resource_hash                             | string              | The hash of a specific resource to filter by.                                                                                                                                                                                                                                                                                         |
| <data_source=apm_metrics>                 | resource_name                             | string              | The full name of a specific resource to filter by.                                                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | service                                   | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_metrics>                 | span_kind                                 | enum                | Describes the relationship between the span, its parents, and its children in a trace. Allowed enum values: `consumer,server,client,producer,internal`                                                                                                                                                                                |
| <data_source=apm_metrics>                 | stat [*required*]                    | enum                | APM metric stat name. Allowed enum values: `errors,error_rate,errors_per_second,latency_avg,latency_max,latency_p50,latency_p75,latency_p90,latency_p95,latency_p99`                                                                                                                                                                  |
| queries                                   | <data_source=slo>                         | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | additional_query_filters                  | string              | Additional filters applied to the SLO query.                                                                                                                                                                                                                                                                                          |
| <data_source=slo>                         | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=slo>                         | data_source [*required*]             | enum                | Data source for SLO measures queries. Allowed enum values: `slo`                                                                                                                                                                                                                                                                      |
| <data_source=slo>                         | group_mode                                | enum                | Group mode to query measures. Allowed enum values: `overall,components`                                                                                                                                                                                                                                                               |
| <data_source=slo>                         | measure [*required*]                 | enum                | SLO measures queries. Allowed enum values: `good_events,bad_events,good_minutes,bad_minutes,slo_status,error_budget_remaining,burn_rate,error_budget_burndown`                                                                                                                                                                        |
| <data_source=slo>                         | name                                      | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | slo_id [*required*]                  | string              | ID of an SLO to query measures.                                                                                                                                                                                                                                                                                                       |
| <data_source=slo>                         | slo_query_type                            | enum                | Name of the query for use in formulas. Allowed enum values: `metric,monitor,time_slice`                                                                                                                                                                                                                                               |
| queries                                   | <data_source=cloud_cost>                  | object              | A formula and functions Cloud Cost query.                                                                                                                                                                                                                                                                                             |
| <data_source=cloud_cost>                  | aggregator                                | enum                | Aggregator used for the request. Allowed enum values: `avg,last,max,min,sum,percentile`                                                                                                                                                                                                                                               |
| <data_source=cloud_cost>                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | data_source [*required*]             | enum                | Data source for Cloud Cost queries. Allowed enum values: `cloud_cost`                                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=cloud_cost>                  | query [*required*]                   | string              | Query for Cloud Cost data.                                                                                                                                                                                                                                                                                                            |
| queries                                   | <data_source=product_analytics_extended>  | object              | A formula and functions Product Analytics Extended query for advanced analytics features.                                                                                                                                                                                                                                             |
| <data_source=product_analytics_extended>  | audience_filters                          | object              | Product Analytics/RUM audience filters.                                                                                                                                                                                                                                                                                               |
| audience_filters                          | accounts                                  | [object]            |
| audience_filters                          | filter_condition                          | string              | An optional filter condition applied to the audience subquery.                                                                                                                                                                                                                                                                        |
| audience_filters                          | segments                                  | [object]            |
| audience_filters                          | users                                     | [object]            |
| <data_source=product_analytics_extended>  | compute [*required*]                 | object              | Compute configuration for Product Analytics Extended queries.                                                                                                                                                                                                                                                                         |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Fixed-width time bucket interval in milliseconds for time series queries. Mutually exclusive with `rollup`.                                                                                                                                                                                                                           |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| compute                                   | name                                      | string              | Name of the compute for use in formulas.                                                                                                                                                                                                                                                                                              |
| compute                                   | rollup                                    | object              | Calendar-aligned time bucket for time series queries (for example, day, week, or month boundaries). Mutually exclusive with `interval`.                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | data_source [*required*]             | enum                | Data source for Product Analytics Extended queries. Allowed enum values: `product_analytics_extended`                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | indexes                                   | [string]            | Event indexes to query.                                                                                                                                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_extended>  | query [*required*]                   | object              | Base query for Product Analytics.                                                                                                                                                                                                                                                                                                     |
| query                                     | data_source [*required*]             | enum                | Data source for Product Analytics event queries. Allowed enum values: `product_analytics`                                                                                                                                                                                                                                             |
| query                                     | search [*required*]                  | object              | Search configuration for Product Analytics event query.                                                                                                                                                                                                                                                                               |
| queries                                   | <data_source=product_analytics_journey>   | object              | A formula and functions User Journey query for defining funnel, timeseries, and scalar visualizations over journey data.                                                                                                                                                                                                              |
| <data_source=product_analytics_journey>   | compute [*required*]                 | object              | Compute configuration for User Journey formula queries.                                                                                                                                                                                                                                                                               |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Time bucket interval in milliseconds for time series queries.                                                                                                                                                                                                                                                                         |
| compute                                   | metric                                    | enum                | Metric for User Journey formula compute. `__dd.conversion` and `__dd.conversion_rate` accept `count` and `cardinality` as aggregations. `__dd.time_to_convert` accepts `avg`, `median`, `pc75`, `pc95`, `pc98`, `pc99`, `min`, and `max`. Allowed enum values: `__dd.conversion,__dd.conversion_rate,__dd.time_to_convert`            |
| compute                                   | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | data_source [*required*]             | enum                | Data source for user journey funnel queries. Allowed enum values: `product_analytics_journey`                                                                                                                                                                                                                                         |
| <data_source=product_analytics_journey>   | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_journey>   | search [*required*]                  | object              | User journey search configuration.                                                                                                                                                                                                                                                                                                    |
| search                                    | expression [*required*]              | string              | Expression string.                                                                                                                                                                                                                                                                                                                    |
| search                                    | filters                                   | object              | Filters for user journey search.                                                                                                                                                                                                                                                                                                      |
| search                                    | join_keys                                 | object              | Join keys for user journey queries.                                                                                                                                                                                                                                                                                                   |
| search                                    | node_objects [*required*]            | object              | Node objects mapping.                                                                                                                                                                                                                                                                                                                 |
| search                                    | step_aliases                              | object              | Step aliases mapping.                                                                                                                                                                                                                                                                                                                 |
| queries                                   | <data_source=product_analytics_retention> | object              | A formula and functions Retention query for defining timeseries and scalar visualizations.                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | compute [*required*]                 | object              | Compute configuration for retention queries.                                                                                                                                                                                                                                                                                          |
| compute                                   | aggregation [*required*]             |  <oneOf>       | The type of aggregation that can be performed on events-based queries.                                                                                                                                                                                                                                                                |
| compute                                   | metric [*required*]                  | enum                | Metric for retention compute. Allowed enum values: `__dd.retention,__dd.retention_rate`                                                                                                                                                                                                                                               |
| <data_source=product_analytics_retention> | data_source [*required*]             | enum                | Data source for retention queries. Allowed enum values: `product_analytics_retention`                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_retention> | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet to group by.                                                                                                                                                                                                                                                                                                                    |
| group_by                                  | limit                                     | int64               | Maximum number of groups.                                                                                                                                                                                                                                                                                                             |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude missing values.                                                                                                                                                                                                                                                                                                    |
| group_by                                  | sort                                      | object              | Sort configuration for retention group by.                                                                                                                                                                                                                                                                                            |
| group_by                                  | source                                    | string              | Source field.                                                                                                                                                                                                                                                                                                                         |
| group_by                                  | target [*required*]                  | enum                | Target for retention group by. Allowed enum values: `cohort,return_period`                                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_retention> | search [*required*]                  | object              | Search configuration for retention queries.                                                                                                                                                                                                                                                                                           |
| search                                    | cohort_criteria [*required*]         | object              | Cohort criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| search                                    | filters                                   | object              | Filters for retention queries.                                                                                                                                                                                                                                                                                                        |
| search                                    | retention_entity [*required*]        | enum                | Entity to track for retention. Allowed enum values: `@usr.id,@account.id`                                                                                                                                                                                                                                                             |
| search                                    | return_condition [*required*]        | enum                | Condition for counting user return. Allowed enum values: `conversion_on,conversion_on_or_after`                                                                                                                                                                                                                                       |
| search                                    | return_criteria                           | object              | Return criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| requests                                  | response_format                           | enum                | Timeseries, scalar, or event list response. Event list response formats are supported by Geomap widgets. Allowed enum values: `timeseries,scalar,event_list`                                                                                                                                                                          |
| requests                                  | rum_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| rum_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| rum_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| rum_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | security_query                            | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| security_query                            | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| security_query                            | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| security_query                            | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | sort                                      | object              | The controls for sorting the widget.                                                                                                                                                                                                                                                                                                  |
| sort                                      | count                                     | int64               | The number of items to limit the widget to.                                                                                                                                                                                                                                                                                           |
| sort                                      | order_by                                  | [ <oneOf>]     | The array of items to sort the widget by in order.                                                                                                                                                                                                                                                                                    |
| order_by                                  | <type=formula>                            | object              | The formula to sort the widget by.                                                                                                                                                                                                                                                                                                    |
| <type=formula>                            | index [*required*]                   | int64               | The index of the formula to sort by.                                                                                                                                                                                                                                                                                                  |
| <type=formula>                            | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| <type=formula>                            | type [*required*]                    | enum                | Set the sort type to formula. Allowed enum values: `formula`                                                                                                                                                                                                                                                                          |
| order_by                                  | <type=group>                              | object              | The group to sort the widget by.                                                                                                                                                                                                                                                                                                      |
| <type=group>                              | name [*required*]                    | string              | The name of the group.                                                                                                                                                                                                                                                                                                                |
| <type=group>                              | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| <type=group>                              | type [*required*]                    | enum                | Set the sort type to group. Allowed enum values: `group`                                                                                                                                                                                                                                                                              |
| requests                                  | style                                     | object              | Define request widget style.                                                                                                                                                                                                                                                                                                          |
| style                                     | line_type                                 | enum                | Type of lines displayed. Allowed enum values: `dashed,dotted,solid`                                                                                                                                                                                                                                                                   |
| style                                     | line_width                                | enum                | Width of line displayed. Allowed enum values: `normal,thick,thin`                                                                                                                                                                                                                                                                     |
| style                                     | order_by                                  | enum                | How to order series in timeseries visualizations.                                                                                                                                                                                                                                                                                     |
| style                                     | palette                                   | string              | Color palette to apply to the widget.                                                                                                                                                                                                                                                                                                 |
| definition                                | style                                     | object              | Style customization for a top list widget.                                                                                                                                                                                                                                                                                            |
| style                                     | display                                   |  <oneOf>       | Top list widget display options.                                                                                                                                                                                                                                                                                                      |
| display                                   | <type=stacked>                            | object              | Top list widget stacked display options.                                                                                                                                                                                                                                                                                              |
| <type=stacked>                            | legend                                    | enum                | Top list widget stacked legend behavior. Allowed enum values: `automatic,inline,none`                                                                                                                                                                                                                                                 |
| <type=stacked>                            | type [*required*]                    | enum                | Top list widget stacked display type. Allowed enum values: `stacked`                                                                                                                                                                                                                                                                  |
| display                                   | <type=flat>                               | object              | Top list widget flat display.                                                                                                                                                                                                                                                                                                         |
| <type=flat>                               | type [*required*]                    | enum                | Top list widget flat display type. Allowed enum values: `flat`                                                                                                                                                                                                                                                                        |
| style                                     | palette                                   | string              | Color palette to apply to the widget.                                                                                                                                                                                                                                                                                                 |
| style                                     | scaling                                   | enum                | Top list widget scaling definition. Allowed enum values: `absolute,relative`                                                                                                                                                                                                                                                          |
| definition                                | time                                      |  <oneOf>       | Time setting for the widget.                                                                                                                                                                                                                                                                                                          |
| time                                      | Object 1                                  | object              | Wrapper for live span                                                                                                                                                                                                                                                                                                                 |
| Object 1                                  | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span                                 | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | <type=live>                               | object              | Used for arbitrary live span times, such as 17 minutes or 6 hours.                                                                                                                                                                                                                                                                    |
| <type=live>                               | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=live>                               | type [*required*]                    | enum                | Type "live" denotes a live span in the new format. Allowed enum values: `live`                                                                                                                                                                                                                                                        |
| <type=live>                               | unit [*required*]                    | enum                | Unit of the time span. Allowed enum values: `minute,hour,day,week,month,year`                                                                                                                                                                                                                                                         |
| <type=live>                               | value [*required*]                   | int64               | Value of the time span.                                                                                                                                                                                                                                                                                                               |
| time                                      | <type=fixed>                              | object              | Used for fixed span times, such as 'March 1 to March 7'.                                                                                                                                                                                                                                                                              |
| <type=fixed>                              | from [*required*]                    | int64               | Start time in milliseconds since epoch.                                                                                                                                                                                                                                                                                               |
| <type=fixed>                              | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=fixed>                              | to [*required*]                      | int64               | End time in milliseconds since epoch.                                                                                                                                                                                                                                                                                                 |
| <type=fixed>                              | type [*required*]                    | enum                | Type "fixed" denotes a fixed span. Allowed enum values: `fixed`                                                                                                                                                                                                                                                                       |
| definition                                | title                                     | string              | Title of your widget.                                                                                                                                                                                                                                                                                                                 |
| definition                                | title_align                               | enum                | How to align the text on the widget. Allowed enum values: `center,left,right`                                                                                                                                                                                                                                                         |
| definition                                | title_size                                | string              | Size of the title.                                                                                                                                                                                                                                                                                                                    |
| definition                                | type [*required*]                    | enum                | Type of the top list widget. Allowed enum values: `toplist`                                                                                                                                                                                                                                                                           |
| Object 3                                  | graph_size                                | enum                | The size of the graph. Allowed enum values: `xs,s,m,l,xl`                                                                                                                                                                                                                                                                             |
| Object 3                                  | split_by                                  | object              | Object describing how to split the graph to display multiple visualizations per request.                                                                                                                                                                                                                                              |
| split_by                                  | keys [*required*]                    | [string]            | Keys to split on.                                                                                                                                                                                                                                                                                                                     |
| split_by                                  | tags [*required*]                    | [string]            | Tags to split on.                                                                                                                                                                                                                                                                                                                     |
| Object 3                                  | time                                      | object <oneOf> | Timeframe for the notebook cell. When 'null', the notebook global time is used.                                                                                                                                                                                                                                                       |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| attributes                                | Object 4                                  | object              | The attributes of a notebook `heatmap` cell.                                                                                                                                                                                                                                                                                          |
| Object 4                                  | definition [*required*]              | object              | The heat map visualization shows metrics aggregated across many tags, such as hosts. The more hosts that have a particular value, the darker that square is.                                                                                                                                                                          |
| definition                                | custom_links                              | [object]            | List of custom links.                                                                                                                                                                                                                                                                                                                 |
| custom_links                              | is_hidden                                 | boolean             | The flag for toggling context menu link visibility.                                                                                                                                                                                                                                                                                   |
| custom_links                              | label                                     | string              | The label for the custom link URL. Keep the label short and descriptive. Use metrics and tags as variables.                                                                                                                                                                                                                           |
| custom_links                              | link                                      | string              | The URL of the custom link. URL must include `http` or `https`. A relative URL must start with `/`.                                                                                                                                                                                                                                   |
| custom_links                              | override_label                            | string              | The label ID that refers to a context menu link. Can be `logs`, `hosts`, `traces`, `profiles`, `processes`, `containers`, or `rum`.                                                                                                                                                                                                   |
| definition                                | description                               | string              | The description of the widget.                                                                                                                                                                                                                                                                                                        |
| definition                                | events                                    | [object]            | **DEPRECATED**: List of widget events. Deprecated - Use `overlay` request type instead.                                                                                                                                                                                                                                               |
| events                                    | q [*required*]                       | string              | Query definition.                                                                                                                                                                                                                                                                                                                     |
| events                                    | tags_execution                            | string              | The execution method for multi-value filters.                                                                                                                                                                                                                                                                                         |
| definition                                | legend_size                               | string              | Available legend sizes for a widget. Should be one of "0", "2", "4", "8", "16", or "auto".                                                                                                                                                                                                                                            |
| definition                                | markers                                   | [object]            | List of markers.                                                                                                                                                                                                                                                                                                                      |
| markers                                   | display_type                              | string              | Combination of:                                                                                                                                                                                                                                                                                                                       |
| markers                                   | label                                     | string              | Label to display over the marker.                                                                                                                                                                                                                                                                                                     |
| markers                                   | time                                      | string              | Timestamp for the widget.                                                                                                                                                                                                                                                                                                             |
| markers                                   | value [*required*]                   | string              | Value to apply. Can be a single value y = 15 or a range of values 0 < y < 10. For Distribution widgets with `display_type` set to `percentile`, this should be a numeric percentile value (for example, "90" for P90).                                                                                                                |
| definition                                | requests [*required*]                | [object]            | List of widget types.                                                                                                                                                                                                                                                                                                                 |
| requests                                  | apm_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| apm_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| apm_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| apm_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | event_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| event_query                               | search [*required*]                  | string              | The query being made on the event.                                                                                                                                                                                                                                                                                                    |
| event_query                               | tags_execution [*required*]          | string              | The execution method for multi-value filters. Can be either and or or.                                                                                                                                                                                                                                                                |
| requests                                  | formulas                                  | [object]            | List of formulas that operate on queries.                                                                                                                                                                                                                                                                                             |
| formulas                                  | alias                                     | string              | Expression alias.                                                                                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode                         | enum                | Define a display mode for the table cell. Allowed enum values: `number,bar,trend`                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode_options                 | object              | Cell display mode options for the widget formula. (only if `cell_display_mode` is set to `trend`).                                                                                                                                                                                                                                    |
| cell_display_mode_options                 | trend_type                                | enum                | Trend type for the cell display mode options. Allowed enum values: `area,line,bars`                                                                                                                                                                                                                                                   |
| cell_display_mode_options                 | y_scale                                   | enum                | Y scale for the cell display mode options. Allowed enum values: `shared,independent`                                                                                                                                                                                                                                                  |
| formulas                                  | conditional_formats                       | [object]            | List of conditional formats.                                                                                                                                                                                                                                                                                                          |
| conditional_formats                       | comparator [*required*]              | enum                | Comparator to apply. Allowed enum values: `=,>,>=,<,<=`                                                                                                                                                                                                                                                                               |
| conditional_formats                       | custom_bg_color                           | string              | Color palette to apply to the background, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | custom_fg_color                           | string              | Color palette to apply to the foreground, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | hide_value                                | boolean             | True hides values.                                                                                                                                                                                                                                                                                                                    |
| conditional_formats                       | image_url                                 | string              | Displays an image as the background.                                                                                                                                                                                                                                                                                                  |
| conditional_formats                       | metric                                    | string              | Metric from the request to correlate this conditional format with.                                                                                                                                                                                                                                                                    |
| conditional_formats                       | palette [*required*]                 | enum                | Color palette to apply. Allowed enum values: `blue,custom_bg,custom_image,custom_text,gray_on_white,grey,green,orange,red,red_on_white`                                                                                                                                                                                               |
| conditional_formats                       | timeframe                                 | string              | Defines the displayed timeframe.                                                                                                                                                                                                                                                                                                      |
| conditional_formats                       | value [*required*]                   | double              | Value for the comparator.                                                                                                                                                                                                                                                                                                             |
| formulas                                  | formula [*required*]                 | string              | String expression built from queries, formulas, and functions.                                                                                                                                                                                                                                                                        |
| formulas                                  | limit                                     | object              | Options for limiting results returned.                                                                                                                                                                                                                                                                                                |
| limit                                     | count                                     | int64               | Number of results to return.                                                                                                                                                                                                                                                                                                          |
| limit                                     | order                                     | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| formulas                                  | number_format                             | object              | Number format options for the widget.                                                                                                                                                                                                                                                                                                 |
| number_format                             | unit                                      |  <oneOf>       | Number format unit.                                                                                                                                                                                                                                                                                                                   |
| unit                                      | <type=canonical_unit>                     | object              | Canonical unit.                                                                                                                                                                                                                                                                                                                       |
| unit                                      | <type=custom_unit_label>                  | object              | Custom unit.                                                                                                                                                                                                                                                                                                                          |
| number_format                             | unit_scale                                | object              | The definition of `NumberFormatUnitScale` object.                                                                                                                                                                                                                                                                                     |
| unit_scale                                | type                                      | enum                | The type of unit scale. Allowed enum values: `canonical_unit`                                                                                                                                                                                                                                                                         |
| unit_scale                                | unit_name                                 | string              | The name of the unit.                                                                                                                                                                                                                                                                                                                 |
| formulas                                  | style                                     | object              | Styling options for widget formulas.                                                                                                                                                                                                                                                                                                  |
| style                                     | palette                                   | string              | The color palette used to display the formula. A guide to the available color palettes can be found at [https://docs.datadoghq.com/dashboards/guide/widget_colors](https://docs.datadoghq.com/dashboards/guide/widget_colors.md)                                                                                                      |
| style                                     | palette_index                             | int64               | Index specifying which color to use within the palette.                                                                                                                                                                                                                                                                               |
| requests                                  | log_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| log_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| log_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| log_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | network_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| network_query                             | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| network_query                             | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| network_query                             | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | process_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| process_query                             | filter_by                                 | [string]            | List of processes.                                                                                                                                                                                                                                                                                                                    |
| process_query                             | limit                                     | int64               | Max number of items in the filter list.                                                                                                                                                                                                                                                                                               |
| process_query                             | metric [*required*]                  | string              | Your chosen metric.                                                                                                                                                                                                                                                                                                                   |
| process_query                             | search_by                                 | string              | Your chosen search term.                                                                                                                                                                                                                                                                                                              |
| requests                                  | profile_metrics_query                     | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| profile_metrics_query                     | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| profile_metrics_query                     | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | q                                         | string              | **DEPRECATED**: Widget query. Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                      |
| requests                                  | queries                                   | [ <oneOf>]     | List of queries that can be returned directly or used in formulas.                                                                                                                                                                                                                                                                    |
| queries                                   | <data_source=metrics>                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| <data_source=metrics>                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=metrics>                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| <data_source=metrics>                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| <data_source=metrics>                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| queries                                   | Object 2                                  | object              | A formula and functions events query.                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | compute [*required*]                 | object              | Compute options.                                                                                                                                                                                                                                                                                                                      |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | int64               | A time interval in milliseconds.                                                                                                                                                                                                                                                                                                      |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| Object 2                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 2                                  | data_source [*required*]             | enum                | Data source for event platform-based queries. Allowed enum values: `logs,spans,network,rum,security_signals,profiles,audit,events,ci_tests,ci_pipelines`                                                                                                                                                                              |
| Object 2                                  | group_by                                  |  <oneOf>       | Group by configuration for a formula and functions events query. Accepts either a list of facet objects or a flat object that specifies a list of facet fields.                                                                                                                                                                       |
| group_by                                  | Object 1                                  | [object]            | List of objects used to group by.                                                                                                                                                                                                                                                                                                     |
| group_by                                  | Object 2                                  | object              | Flat group by configuration using multiple event facet fields.                                                                                                                                                                                                                                                                        |
| Object 2                                  | indexes                                   | [string]            | An array of index names to query in the stream. Omit or use `[]` to query all indexes at once.                                                                                                                                                                                                                                        |
| Object 2                                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| Object 2                                  | search                                    | object              | Search options.                                                                                                                                                                                                                                                                                                                       |
| search                                    | query [*required*]                   | string              | Events search string.                                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | storage                                   | string              | Option for storage location. Feature in Private Beta.                                                                                                                                                                                                                                                                                 |
| queries                                   | Object 3                                  | object              | Process query using formulas and functions.                                                                                                                                                                                                                                                                                           |
| Object 3                                  | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| Object 3                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 3                                  | data_source [*required*]             | enum                | Data sources that rely on the process backend. Allowed enum values: `process,container`                                                                                                                                                                                                                                               |
| Object 3                                  | is_normalized_cpu                         | boolean             | Whether to normalize the CPU percentages.                                                                                                                                                                                                                                                                                             |
| Object 3                                  | limit                                     | int64               | Number of hits to return.                                                                                                                                                                                                                                                                                                             |
| Object 3                                  | metric [*required*]                  | string              | Process metric name.                                                                                                                                                                                                                                                                                                                  |
| Object 3                                  | name [*required*]                    | string              | Name of query for use in formulas.                                                                                                                                                                                                                                                                                                    |
| Object 3                                  | sort                                      | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| Object 3                                  | tag_filters                               | [string]            | An array of tags to filter by.                                                                                                                                                                                                                                                                                                        |
| Object 3                                  | text_filter                               | string              | Text to use as filter.                                                                                                                                                                                                                                                                                                                |
| queries                                   | <data_source=apm_dependency_stats>        | object              | A formula and functions APM dependency stats query.                                                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | data_source [*required*]             | enum                | Data source for APM dependency stats queries. Allowed enum values: `apm_dependency_stats`                                                                                                                                                                                                                                             |
| <data_source=apm_dependency_stats>        | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_dependency_stats>        | is_upstream                               | boolean             | Determines whether stats for upstream or downstream dependencies should be queried.                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | name [*required*]                    | string              | Name of query to use in formulas.                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_dependency_stats>        | operation_name [*required*]          | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | primary_tag_name                          | string              | The name of the second primary tag used within APM; required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog). |
| <data_source=apm_dependency_stats>        | primary_tag_value                         | string              | Filter APM data by the second primary tag. `primary_tag_name` must also be specified.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | resource_name [*required*]           | string              | APM resource.                                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | service [*required*]                 | string              | APM service.                                                                                                                                                                                                                                                                                                                          |
| <data_source=apm_dependency_stats>        | stat [*required*]                    | enum                | APM statistic. Allowed enum values: `avg_duration,avg_root_duration,avg_spans_per_trace,error_rate,pct_exec_time,pct_of_traces,total_traces_count`                                                                                                                                                                                    |
| queries                                   | <data_source=apm_resource_stats>          | object              | **DEPRECATED**: APM resource stats query using formulas and functions. Deprecated - Use `apm_metrics` query type instead.                                                                                                                                                                                                             |
| <data_source=apm_resource_stats>          | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | data_source [*required*]             | enum                | Data source for APM resource stats queries. Allowed enum values: `apm_resource_stats`                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_resource_stats>          | group_by                                  | [string]            | Array of fields to group results by.                                                                                                                                                                                                                                                                                                  |
| <data_source=apm_resource_stats>          | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_resource_stats>          | operation_name                            | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_resource_stats>          | primary_tag_name                          | string              | Name of the second primary tag used within APM. Required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog)      |
| <data_source=apm_resource_stats>          | primary_tag_value                         | string              | Value of the second primary tag by which to filter APM data. `primary_tag_name` must also be specified.                                                                                                                                                                                                                               |
| <data_source=apm_resource_stats>          | resource_name                             | string              | APM resource name.                                                                                                                                                                                                                                                                                                                    |
| <data_source=apm_resource_stats>          | service [*required*]                 | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_resource_stats>          | stat [*required*]                    | enum                | APM resource stat name. Allowed enum values: `errors,error_rate,hits,latency_avg,latency_distribution,latency_max,latency_p50,latency_p75,latency_p90,latency_p95`                                                                                                                                                                    |
| queries                                   | <data_source=apm_metrics>                 | object              | A formula and functions APM metrics query.                                                                                                                                                                                                                                                                                            |
| <data_source=apm_metrics>                 | data_source [*required*]             | enum                | Data source for APM metrics queries. Allowed enum values: `apm_metrics`                                                                                                                                                                                                                                                               |
| <data_source=apm_metrics>                 | group_by                                  | [string]            | Optional fields to group the query results by.                                                                                                                                                                                                                                                                                        |
| <data_source=apm_metrics>                 | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_metrics>                 | operation_mode                            | string              | Optional operation mode to aggregate across operation names.                                                                                                                                                                                                                                                                          |
| <data_source=apm_metrics>                 | operation_name                            | string              | Name of operation on service. If not provided, the primary operation name is used.                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | peer_tags                                 | [string]            | Tags to query for a specific downstream entity (peer.service, peer.db_instance, peer.s3, peer.s3.bucket, etc.).                                                                                                                                                                                                                       |
| <data_source=apm_metrics>                 | query_filter                              | string              | Additional filters for the query using metrics query syntax (e.g., env, primary_tag).                                                                                                                                                                                                                                                 |
| <data_source=apm_metrics>                 | resource_hash                             | string              | The hash of a specific resource to filter by.                                                                                                                                                                                                                                                                                         |
| <data_source=apm_metrics>                 | resource_name                             | string              | The full name of a specific resource to filter by.                                                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | service                                   | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_metrics>                 | span_kind                                 | enum                | Describes the relationship between the span, its parents, and its children in a trace. Allowed enum values: `consumer,server,client,producer,internal`                                                                                                                                                                                |
| <data_source=apm_metrics>                 | stat [*required*]                    | enum                | APM metric stat name. Allowed enum values: `errors,error_rate,errors_per_second,latency_avg,latency_max,latency_p50,latency_p75,latency_p90,latency_p95,latency_p99`                                                                                                                                                                  |
| queries                                   | <data_source=slo>                         | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | additional_query_filters                  | string              | Additional filters applied to the SLO query.                                                                                                                                                                                                                                                                                          |
| <data_source=slo>                         | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=slo>                         | data_source [*required*]             | enum                | Data source for SLO measures queries. Allowed enum values: `slo`                                                                                                                                                                                                                                                                      |
| <data_source=slo>                         | group_mode                                | enum                | Group mode to query measures. Allowed enum values: `overall,components`                                                                                                                                                                                                                                                               |
| <data_source=slo>                         | measure [*required*]                 | enum                | SLO measures queries. Allowed enum values: `good_events,bad_events,good_minutes,bad_minutes,slo_status,error_budget_remaining,burn_rate,error_budget_burndown`                                                                                                                                                                        |
| <data_source=slo>                         | name                                      | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | slo_id [*required*]                  | string              | ID of an SLO to query measures.                                                                                                                                                                                                                                                                                                       |
| <data_source=slo>                         | slo_query_type                            | enum                | Name of the query for use in formulas. Allowed enum values: `metric,monitor,time_slice`                                                                                                                                                                                                                                               |
| queries                                   | <data_source=cloud_cost>                  | object              | A formula and functions Cloud Cost query.                                                                                                                                                                                                                                                                                             |
| <data_source=cloud_cost>                  | aggregator                                | enum                | Aggregator used for the request. Allowed enum values: `avg,last,max,min,sum,percentile`                                                                                                                                                                                                                                               |
| <data_source=cloud_cost>                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | data_source [*required*]             | enum                | Data source for Cloud Cost queries. Allowed enum values: `cloud_cost`                                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=cloud_cost>                  | query [*required*]                   | string              | Query for Cloud Cost data.                                                                                                                                                                                                                                                                                                            |
| queries                                   | <data_source=product_analytics_extended>  | object              | A formula and functions Product Analytics Extended query for advanced analytics features.                                                                                                                                                                                                                                             |
| <data_source=product_analytics_extended>  | audience_filters                          | object              | Product Analytics/RUM audience filters.                                                                                                                                                                                                                                                                                               |
| audience_filters                          | accounts                                  | [object]            |
| audience_filters                          | filter_condition                          | string              | An optional filter condition applied to the audience subquery.                                                                                                                                                                                                                                                                        |
| audience_filters                          | segments                                  | [object]            |
| audience_filters                          | users                                     | [object]            |
| <data_source=product_analytics_extended>  | compute [*required*]                 | object              | Compute configuration for Product Analytics Extended queries.                                                                                                                                                                                                                                                                         |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Fixed-width time bucket interval in milliseconds for time series queries. Mutually exclusive with `rollup`.                                                                                                                                                                                                                           |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| compute                                   | name                                      | string              | Name of the compute for use in formulas.                                                                                                                                                                                                                                                                                              |
| compute                                   | rollup                                    | object              | Calendar-aligned time bucket for time series queries (for example, day, week, or month boundaries). Mutually exclusive with `interval`.                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | data_source [*required*]             | enum                | Data source for Product Analytics Extended queries. Allowed enum values: `product_analytics_extended`                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | indexes                                   | [string]            | Event indexes to query.                                                                                                                                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_extended>  | query [*required*]                   | object              | Base query for Product Analytics.                                                                                                                                                                                                                                                                                                     |
| query                                     | data_source [*required*]             | enum                | Data source for Product Analytics event queries. Allowed enum values: `product_analytics`                                                                                                                                                                                                                                             |
| query                                     | search [*required*]                  | object              | Search configuration for Product Analytics event query.                                                                                                                                                                                                                                                                               |
| queries                                   | <data_source=product_analytics_journey>   | object              | A formula and functions User Journey query for defining funnel, timeseries, and scalar visualizations over journey data.                                                                                                                                                                                                              |
| <data_source=product_analytics_journey>   | compute [*required*]                 | object              | Compute configuration for User Journey formula queries.                                                                                                                                                                                                                                                                               |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Time bucket interval in milliseconds for time series queries.                                                                                                                                                                                                                                                                         |
| compute                                   | metric                                    | enum                | Metric for User Journey formula compute. `__dd.conversion` and `__dd.conversion_rate` accept `count` and `cardinality` as aggregations. `__dd.time_to_convert` accepts `avg`, `median`, `pc75`, `pc95`, `pc98`, `pc99`, `min`, and `max`. Allowed enum values: `__dd.conversion,__dd.conversion_rate,__dd.time_to_convert`            |
| compute                                   | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | data_source [*required*]             | enum                | Data source for user journey funnel queries. Allowed enum values: `product_analytics_journey`                                                                                                                                                                                                                                         |
| <data_source=product_analytics_journey>   | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_journey>   | search [*required*]                  | object              | User journey search configuration.                                                                                                                                                                                                                                                                                                    |
| search                                    | expression [*required*]              | string              | Expression string.                                                                                                                                                                                                                                                                                                                    |
| search                                    | filters                                   | object              | Filters for user journey search.                                                                                                                                                                                                                                                                                                      |
| search                                    | join_keys                                 | object              | Join keys for user journey queries.                                                                                                                                                                                                                                                                                                   |
| search                                    | node_objects [*required*]            | object              | Node objects mapping.                                                                                                                                                                                                                                                                                                                 |
| search                                    | step_aliases                              | object              | Step aliases mapping.                                                                                                                                                                                                                                                                                                                 |
| queries                                   | <data_source=product_analytics_retention> | object              | A formula and functions Retention query for defining timeseries and scalar visualizations.                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | compute [*required*]                 | object              | Compute configuration for retention queries.                                                                                                                                                                                                                                                                                          |
| compute                                   | aggregation [*required*]             |  <oneOf>       | The type of aggregation that can be performed on events-based queries.                                                                                                                                                                                                                                                                |
| compute                                   | metric [*required*]                  | enum                | Metric for retention compute. Allowed enum values: `__dd.retention,__dd.retention_rate`                                                                                                                                                                                                                                               |
| <data_source=product_analytics_retention> | data_source [*required*]             | enum                | Data source for retention queries. Allowed enum values: `product_analytics_retention`                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_retention> | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet to group by.                                                                                                                                                                                                                                                                                                                    |
| group_by                                  | limit                                     | int64               | Maximum number of groups.                                                                                                                                                                                                                                                                                                             |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude missing values.                                                                                                                                                                                                                                                                                                    |
| group_by                                  | sort                                      | object              | Sort configuration for retention group by.                                                                                                                                                                                                                                                                                            |
| group_by                                  | source                                    | string              | Source field.                                                                                                                                                                                                                                                                                                                         |
| group_by                                  | target [*required*]                  | enum                | Target for retention group by. Allowed enum values: `cohort,return_period`                                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_retention> | search [*required*]                  | object              | Search configuration for retention queries.                                                                                                                                                                                                                                                                                           |
| search                                    | cohort_criteria [*required*]         | object              | Cohort criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| search                                    | filters                                   | object              | Filters for retention queries.                                                                                                                                                                                                                                                                                                        |
| search                                    | retention_entity [*required*]        | enum                | Entity to track for retention. Allowed enum values: `@usr.id,@account.id`                                                                                                                                                                                                                                                             |
| search                                    | return_condition [*required*]        | enum                | Condition for counting user return. Allowed enum values: `conversion_on,conversion_on_or_after`                                                                                                                                                                                                                                       |
| search                                    | return_criteria                           | object              | Return criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| requests                                  | query                                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| query                                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| query                                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| query                                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| query                                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| query                                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| query                                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| requests                                  | request_type                              | enum                | Applicable only for distribution of point values for distribution metrics. Allowed enum values: `histogram`                                                                                                                                                                                                                           |
| requests                                  | response_format                           | enum                | Applicable only for distribution of aggregated grouped queries. Allowed enum values: `timeseries,scalar,event_list`                                                                                                                                                                                                                   |
| requests                                  | rum_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| rum_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| rum_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| rum_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | security_query                            | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| security_query                            | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| security_query                            | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| security_query                            | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | style                                     | object              | Widget style definition.                                                                                                                                                                                                                                                                                                              |
| style                                     | palette                                   | string              | Color palette to apply to the widget.                                                                                                                                                                                                                                                                                                 |
| definition                                | show_legend                               | boolean             | Whether or not to display the legend on this widget.                                                                                                                                                                                                                                                                                  |
| definition                                | time                                      |  <oneOf>       | Time setting for the widget.                                                                                                                                                                                                                                                                                                          |
| time                                      | Object 1                                  | object              | Wrapper for live span                                                                                                                                                                                                                                                                                                                 |
| Object 1                                  | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span                                 | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | <type=live>                               | object              | Used for arbitrary live span times, such as 17 minutes or 6 hours.                                                                                                                                                                                                                                                                    |
| <type=live>                               | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=live>                               | type [*required*]                    | enum                | Type "live" denotes a live span in the new format. Allowed enum values: `live`                                                                                                                                                                                                                                                        |
| <type=live>                               | unit [*required*]                    | enum                | Unit of the time span. Allowed enum values: `minute,hour,day,week,month,year`                                                                                                                                                                                                                                                         |
| <type=live>                               | value [*required*]                   | int64               | Value of the time span.                                                                                                                                                                                                                                                                                                               |
| time                                      | <type=fixed>                              | object              | Used for fixed span times, such as 'March 1 to March 7'.                                                                                                                                                                                                                                                                              |
| <type=fixed>                              | from [*required*]                    | int64               | Start time in milliseconds since epoch.                                                                                                                                                                                                                                                                                               |
| <type=fixed>                              | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=fixed>                              | to [*required*]                      | int64               | End time in milliseconds since epoch.                                                                                                                                                                                                                                                                                                 |
| <type=fixed>                              | type [*required*]                    | enum                | Type "fixed" denotes a fixed span. Allowed enum values: `fixed`                                                                                                                                                                                                                                                                       |
| definition                                | title                                     | string              | Title of the widget.                                                                                                                                                                                                                                                                                                                  |
| definition                                | title_align                               | enum                | How to align the text on the widget. Allowed enum values: `center,left,right`                                                                                                                                                                                                                                                         |
| definition                                | title_size                                | string              | Size of the title.                                                                                                                                                                                                                                                                                                                    |
| definition                                | type [*required*]                    | enum                | Type of the heat map widget. Allowed enum values: `heatmap`                                                                                                                                                                                                                                                                           |
| definition                                | xaxis                                     | object              | X Axis controls for the heat map widget.                                                                                                                                                                                                                                                                                              |
| xaxis                                     | num_buckets                               | int64               | Number of time buckets to target, also known as the resolution of the time bins. This is only applicable for distribution of points (group distributions use the roll-up modifier).                                                                                                                                                   |
| definition                                | yaxis                                     | object              | Axis controls for the widget.                                                                                                                                                                                                                                                                                                         |
| yaxis                                     | include_zero                              | boolean             | Set to `true` to include zero.                                                                                                                                                                                                                                                                                                        |
| yaxis                                     | label                                     | string              | The label of the axis to display on the graph. Only usable on Scatterplot Widgets.                                                                                                                                                                                                                                                    |
| yaxis                                     | max                                       | string              | Specifies maximum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| yaxis                                     | min                                       | string              | Specifies minimum numeric value to show on the axis. Defaults to `auto`.                                                                                                                                                                                                                                                              |
| yaxis                                     | scale                                     | string              | Specifies the scale type. Possible values are `linear`, `log`, `sqrt`, and `pow##` (for example `pow2` or `pow0.5`).                                                                                                                                                                                                                  |
| Object 4                                  | graph_size                                | enum                | The size of the graph. Allowed enum values: `xs,s,m,l,xl`                                                                                                                                                                                                                                                                             |
| Object 4                                  | split_by                                  | object              | Object describing how to split the graph to display multiple visualizations per request.                                                                                                                                                                                                                                              |
| split_by                                  | keys [*required*]                    | [string]            | Keys to split on.                                                                                                                                                                                                                                                                                                                     |
| split_by                                  | tags [*required*]                    | [string]            | Tags to split on.                                                                                                                                                                                                                                                                                                                     |
| Object 4                                  | time                                      | object <oneOf> | Timeframe for the notebook cell. When 'null', the notebook global time is used.                                                                                                                                                                                                                                                       |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| attributes                                | Object 5                                  | object              | The attributes of a notebook `distribution` cell.                                                                                                                                                                                                                                                                                     |
| Object 5                                  | definition [*required*]              | object              | The Distribution visualization is another way of showing metrics aggregated across one or several tags, such as hosts. Unlike the heat map, a distribution graph's x-axis is quantity rather than time.                                                                                                                               |
| definition                                | custom_links                              | [object]            | A list of custom links.                                                                                                                                                                                                                                                                                                               |
| custom_links                              | is_hidden                                 | boolean             | The flag for toggling context menu link visibility.                                                                                                                                                                                                                                                                                   |
| custom_links                              | label                                     | string              | The label for the custom link URL. Keep the label short and descriptive. Use metrics and tags as variables.                                                                                                                                                                                                                           |
| custom_links                              | link                                      | string              | The URL of the custom link. URL must include `http` or `https`. A relative URL must start with `/`.                                                                                                                                                                                                                                   |
| custom_links                              | override_label                            | string              | The label ID that refers to a context menu link. Can be `logs`, `hosts`, `traces`, `profiles`, `processes`, `containers`, or `rum`.                                                                                                                                                                                                   |
| definition                                | description                               | string              | The description of the widget.                                                                                                                                                                                                                                                                                                        |
| definition                                | legend_size                               | string              | **DEPRECATED**: (Deprecated) The widget legend was replaced by a tooltip and sidebar.                                                                                                                                                                                                                                                 |
| definition                                | markers                                   | [object]            | List of markers.                                                                                                                                                                                                                                                                                                                      |
| markers                                   | display_type                              | string              | Combination of:                                                                                                                                                                                                                                                                                                                       |
| markers                                   | label                                     | string              | Label to display over the marker.                                                                                                                                                                                                                                                                                                     |
| markers                                   | time                                      | string              | Timestamp for the widget.                                                                                                                                                                                                                                                                                                             |
| markers                                   | value [*required*]                   | string              | Value to apply. Can be a single value y = 15 or a range of values 0 < y < 10. For Distribution widgets with `display_type` set to `percentile`, this should be a numeric percentile value (for example, "90" for P90).                                                                                                                |
| definition                                | requests [*required*]                | [object]            | Array of one request object to display in the widget.                                                                                                                                                                                                                                                                                 | See the dedicated [Request JSON schema documentation](https://docs.datadoghq.com/dashboards/graphing_json/request_json.md) to learn how to build the `REQUEST_SCHEMA`. |
| requests                                  | apm_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| apm_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| apm_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| apm_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| apm_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | apm_stats_query                           | object              | The APM stats query for table and distributions widgets.                                                                                                                                                                                                                                                                              |
| apm_stats_query                           | columns                                   | [object]            | Column properties used by the front end for display.                                                                                                                                                                                                                                                                                  |
| columns                                   | alias                                     | string              | A user-assigned alias for the column.                                                                                                                                                                                                                                                                                                 |
| columns                                   | cell_display_mode                         | enum                | Define a display mode for the table cell. Allowed enum values: `number,bar,trend`                                                                                                                                                                                                                                                     |
| columns                                   | name [*required*]                    | string              | Column name.                                                                                                                                                                                                                                                                                                                          |
| columns                                   | order                                     | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| apm_stats_query                           | env [*required*]                     | string              | Environment name.                                                                                                                                                                                                                                                                                                                     |
| apm_stats_query                           | name [*required*]                    | string              | Operation name associated with service.                                                                                                                                                                                                                                                                                               |
| apm_stats_query                           | primary_tag [*required*]             | string              | The organization's host group name and value.                                                                                                                                                                                                                                                                                         |
| apm_stats_query                           | resource                                  | string              | Resource name.                                                                                                                                                                                                                                                                                                                        |
| apm_stats_query                           | row_type [*required*]                | enum                | The level of detail for the request. Allowed enum values: `service,resource,span`                                                                                                                                                                                                                                                     |
| apm_stats_query                           | service [*required*]                 | string              | Service name.                                                                                                                                                                                                                                                                                                                         |
| requests                                  | event_query                               | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| event_query                               | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| event_query                               | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| event_query                               | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| event_query                               | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | formulas                                  | [object]            | List of formulas that operate on queries.                                                                                                                                                                                                                                                                                             |
| formulas                                  | alias                                     | string              | Expression alias.                                                                                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode                         | enum                | Define a display mode for the table cell. Allowed enum values: `number,bar,trend`                                                                                                                                                                                                                                                     |
| formulas                                  | cell_display_mode_options                 | object              | Cell display mode options for the widget formula. (only if `cell_display_mode` is set to `trend`).                                                                                                                                                                                                                                    |
| cell_display_mode_options                 | trend_type                                | enum                | Trend type for the cell display mode options. Allowed enum values: `area,line,bars`                                                                                                                                                                                                                                                   |
| cell_display_mode_options                 | y_scale                                   | enum                | Y scale for the cell display mode options. Allowed enum values: `shared,independent`                                                                                                                                                                                                                                                  |
| formulas                                  | conditional_formats                       | [object]            | List of conditional formats.                                                                                                                                                                                                                                                                                                          |
| conditional_formats                       | comparator [*required*]              | enum                | Comparator to apply. Allowed enum values: `=,>,>=,<,<=`                                                                                                                                                                                                                                                                               |
| conditional_formats                       | custom_bg_color                           | string              | Color palette to apply to the background, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | custom_fg_color                           | string              | Color palette to apply to the foreground, same values available as palette.                                                                                                                                                                                                                                                           |
| conditional_formats                       | hide_value                                | boolean             | True hides values.                                                                                                                                                                                                                                                                                                                    |
| conditional_formats                       | image_url                                 | string              | Displays an image as the background.                                                                                                                                                                                                                                                                                                  |
| conditional_formats                       | metric                                    | string              | Metric from the request to correlate this conditional format with.                                                                                                                                                                                                                                                                    |
| conditional_formats                       | palette [*required*]                 | enum                | Color palette to apply. Allowed enum values: `blue,custom_bg,custom_image,custom_text,gray_on_white,grey,green,orange,red,red_on_white`                                                                                                                                                                                               |
| conditional_formats                       | timeframe                                 | string              | Defines the displayed timeframe.                                                                                                                                                                                                                                                                                                      |
| conditional_formats                       | value [*required*]                   | double              | Value for the comparator.                                                                                                                                                                                                                                                                                                             |
| formulas                                  | formula [*required*]                 | string              | String expression built from queries, formulas, and functions.                                                                                                                                                                                                                                                                        |
| formulas                                  | limit                                     | object              | Options for limiting results returned.                                                                                                                                                                                                                                                                                                |
| limit                                     | count                                     | int64               | Number of results to return.                                                                                                                                                                                                                                                                                                          |
| limit                                     | order                                     | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| formulas                                  | number_format                             | object              | Number format options for the widget.                                                                                                                                                                                                                                                                                                 |
| number_format                             | unit                                      |  <oneOf>       | Number format unit.                                                                                                                                                                                                                                                                                                                   |
| unit                                      | <type=canonical_unit>                     | object              | Canonical unit.                                                                                                                                                                                                                                                                                                                       |
| unit                                      | <type=custom_unit_label>                  | object              | Custom unit.                                                                                                                                                                                                                                                                                                                          |
| number_format                             | unit_scale                                | object              | The definition of `NumberFormatUnitScale` object.                                                                                                                                                                                                                                                                                     |
| unit_scale                                | type                                      | enum                | The type of unit scale. Allowed enum values: `canonical_unit`                                                                                                                                                                                                                                                                         |
| unit_scale                                | unit_name                                 | string              | The name of the unit.                                                                                                                                                                                                                                                                                                                 |
| formulas                                  | style                                     | object              | Styling options for widget formulas.                                                                                                                                                                                                                                                                                                  |
| style                                     | palette                                   | string              | The color palette used to display the formula. A guide to the available color palettes can be found at [https://docs.datadoghq.com/dashboards/guide/widget_colors](https://docs.datadoghq.com/dashboards/guide/widget_colors.md)                                                                                                      |
| style                                     | palette_index                             | int64               | Index specifying which color to use within the palette.                                                                                                                                                                                                                                                                               |
| requests                                  | log_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| log_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| log_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| log_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| log_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | network_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| network_query                             | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| network_query                             | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| network_query                             | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| network_query                             | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | process_query                             | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| process_query                             | filter_by                                 | [string]            | List of processes.                                                                                                                                                                                                                                                                                                                    |
| process_query                             | limit                                     | int64               | Max number of items in the filter list.                                                                                                                                                                                                                                                                                               |
| process_query                             | metric [*required*]                  | string              | Your chosen metric.                                                                                                                                                                                                                                                                                                                   |
| process_query                             | search_by                                 | string              | Your chosen search term.                                                                                                                                                                                                                                                                                                              |
| requests                                  | profile_metrics_query                     | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| profile_metrics_query                     | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| profile_metrics_query                     | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| profile_metrics_query                     | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | q                                         | string              | **DEPRECATED**: Widget query. Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                      |
| requests                                  | queries                                   | [ <oneOf>]     | List of queries that can be returned directly or used in formulas.                                                                                                                                                                                                                                                                    |
| queries                                   | <data_source=metrics>                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| <data_source=metrics>                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=metrics>                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| <data_source=metrics>                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| <data_source=metrics>                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| queries                                   | Object 2                                  | object              | A formula and functions events query.                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | compute [*required*]                 | object              | Compute options.                                                                                                                                                                                                                                                                                                                      |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | int64               | A time interval in milliseconds.                                                                                                                                                                                                                                                                                                      |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| Object 2                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 2                                  | data_source [*required*]             | enum                | Data source for event platform-based queries. Allowed enum values: `logs,spans,network,rum,security_signals,profiles,audit,events,ci_tests,ci_pipelines`                                                                                                                                                                              |
| Object 2                                  | group_by                                  |  <oneOf>       | Group by configuration for a formula and functions events query. Accepts either a list of facet objects or a flat object that specifies a list of facet fields.                                                                                                                                                                       |
| group_by                                  | Object 1                                  | [object]            | List of objects used to group by.                                                                                                                                                                                                                                                                                                     |
| group_by                                  | Object 2                                  | object              | Flat group by configuration using multiple event facet fields.                                                                                                                                                                                                                                                                        |
| Object 2                                  | indexes                                   | [string]            | An array of index names to query in the stream. Omit or use `[]` to query all indexes at once.                                                                                                                                                                                                                                        |
| Object 2                                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| Object 2                                  | search                                    | object              | Search options.                                                                                                                                                                                                                                                                                                                       |
| search                                    | query [*required*]                   | string              | Events search string.                                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | storage                                   | string              | Option for storage location. Feature in Private Beta.                                                                                                                                                                                                                                                                                 |
| queries                                   | Object 3                                  | object              | Process query using formulas and functions.                                                                                                                                                                                                                                                                                           |
| Object 3                                  | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| Object 3                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 3                                  | data_source [*required*]             | enum                | Data sources that rely on the process backend. Allowed enum values: `process,container`                                                                                                                                                                                                                                               |
| Object 3                                  | is_normalized_cpu                         | boolean             | Whether to normalize the CPU percentages.                                                                                                                                                                                                                                                                                             |
| Object 3                                  | limit                                     | int64               | Number of hits to return.                                                                                                                                                                                                                                                                                                             |
| Object 3                                  | metric [*required*]                  | string              | Process metric name.                                                                                                                                                                                                                                                                                                                  |
| Object 3                                  | name [*required*]                    | string              | Name of query for use in formulas.                                                                                                                                                                                                                                                                                                    |
| Object 3                                  | sort                                      | enum                | Direction of sort. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                                    |
| Object 3                                  | tag_filters                               | [string]            | An array of tags to filter by.                                                                                                                                                                                                                                                                                                        |
| Object 3                                  | text_filter                               | string              | Text to use as filter.                                                                                                                                                                                                                                                                                                                |
| queries                                   | <data_source=apm_dependency_stats>        | object              | A formula and functions APM dependency stats query.                                                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | data_source [*required*]             | enum                | Data source for APM dependency stats queries. Allowed enum values: `apm_dependency_stats`                                                                                                                                                                                                                                             |
| <data_source=apm_dependency_stats>        | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_dependency_stats>        | is_upstream                               | boolean             | Determines whether stats for upstream or downstream dependencies should be queried.                                                                                                                                                                                                                                                   |
| <data_source=apm_dependency_stats>        | name [*required*]                    | string              | Name of query to use in formulas.                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_dependency_stats>        | operation_name [*required*]          | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | primary_tag_name                          | string              | The name of the second primary tag used within APM; required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog). |
| <data_source=apm_dependency_stats>        | primary_tag_value                         | string              | Filter APM data by the second primary tag. `primary_tag_name` must also be specified.                                                                                                                                                                                                                                                 |
| <data_source=apm_dependency_stats>        | resource_name [*required*]           | string              | APM resource.                                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_dependency_stats>        | service [*required*]                 | string              | APM service.                                                                                                                                                                                                                                                                                                                          |
| <data_source=apm_dependency_stats>        | stat [*required*]                    | enum                | APM statistic. Allowed enum values: `avg_duration,avg_root_duration,avg_spans_per_trace,error_rate,pct_exec_time,pct_of_traces,total_traces_count`                                                                                                                                                                                    |
| queries                                   | <data_source=apm_resource_stats>          | object              | **DEPRECATED**: APM resource stats query using formulas and functions. Deprecated - Use `apm_metrics` query type instead.                                                                                                                                                                                                             |
| <data_source=apm_resource_stats>          | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | data_source [*required*]             | enum                | Data source for APM resource stats queries. Allowed enum values: `apm_resource_stats`                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_resource_stats>          | group_by                                  | [string]            | Array of fields to group results by.                                                                                                                                                                                                                                                                                                  |
| <data_source=apm_resource_stats>          | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_resource_stats>          | operation_name                            | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_resource_stats>          | primary_tag_name                          | string              | Name of the second primary tag used within APM. Required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog)      |
| <data_source=apm_resource_stats>          | primary_tag_value                         | string              | Value of the second primary tag by which to filter APM data. `primary_tag_name` must also be specified.                                                                                                                                                                                                                               |
| <data_source=apm_resource_stats>          | resource_name                             | string              | APM resource name.                                                                                                                                                                                                                                                                                                                    |
| <data_source=apm_resource_stats>          | service [*required*]                 | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_resource_stats>          | stat [*required*]                    | enum                | APM resource stat name. Allowed enum values: `errors,error_rate,hits,latency_avg,latency_distribution,latency_max,latency_p50,latency_p75,latency_p90,latency_p95`                                                                                                                                                                    |
| queries                                   | <data_source=apm_metrics>                 | object              | A formula and functions APM metrics query.                                                                                                                                                                                                                                                                                            |
| <data_source=apm_metrics>                 | data_source [*required*]             | enum                | Data source for APM metrics queries. Allowed enum values: `apm_metrics`                                                                                                                                                                                                                                                               |
| <data_source=apm_metrics>                 | group_by                                  | [string]            | Optional fields to group the query results by.                                                                                                                                                                                                                                                                                        |
| <data_source=apm_metrics>                 | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_metrics>                 | operation_mode                            | string              | Optional operation mode to aggregate across operation names.                                                                                                                                                                                                                                                                          |
| <data_source=apm_metrics>                 | operation_name                            | string              | Name of operation on service. If not provided, the primary operation name is used.                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | peer_tags                                 | [string]            | Tags to query for a specific downstream entity (peer.service, peer.db_instance, peer.s3, peer.s3.bucket, etc.).                                                                                                                                                                                                                       |
| <data_source=apm_metrics>                 | query_filter                              | string              | Additional filters for the query using metrics query syntax (e.g., env, primary_tag).                                                                                                                                                                                                                                                 |
| <data_source=apm_metrics>                 | resource_hash                             | string              | The hash of a specific resource to filter by.                                                                                                                                                                                                                                                                                         |
| <data_source=apm_metrics>                 | resource_name                             | string              | The full name of a specific resource to filter by.                                                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | service                                   | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_metrics>                 | span_kind                                 | enum                | Describes the relationship between the span, its parents, and its children in a trace. Allowed enum values: `consumer,server,client,producer,internal`                                                                                                                                                                                |
| <data_source=apm_metrics>                 | stat [*required*]                    | enum                | APM metric stat name. Allowed enum values: `errors,error_rate,errors_per_second,latency_avg,latency_max,latency_p50,latency_p75,latency_p90,latency_p95,latency_p99`                                                                                                                                                                  |
| queries                                   | <data_source=slo>                         | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | additional_query_filters                  | string              | Additional filters applied to the SLO query.                                                                                                                                                                                                                                                                                          |
| <data_source=slo>                         | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=slo>                         | data_source [*required*]             | enum                | Data source for SLO measures queries. Allowed enum values: `slo`                                                                                                                                                                                                                                                                      |
| <data_source=slo>                         | group_mode                                | enum                | Group mode to query measures. Allowed enum values: `overall,components`                                                                                                                                                                                                                                                               |
| <data_source=slo>                         | measure [*required*]                 | enum                | SLO measures queries. Allowed enum values: `good_events,bad_events,good_minutes,bad_minutes,slo_status,error_budget_remaining,burn_rate,error_budget_burndown`                                                                                                                                                                        |
| <data_source=slo>                         | name                                      | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=slo>                         | slo_id [*required*]                  | string              | ID of an SLO to query measures.                                                                                                                                                                                                                                                                                                       |
| <data_source=slo>                         | slo_query_type                            | enum                | Name of the query for use in formulas. Allowed enum values: `metric,monitor,time_slice`                                                                                                                                                                                                                                               |
| queries                                   | <data_source=cloud_cost>                  | object              | A formula and functions Cloud Cost query.                                                                                                                                                                                                                                                                                             |
| <data_source=cloud_cost>                  | aggregator                                | enum                | Aggregator used for the request. Allowed enum values: `avg,last,max,min,sum,percentile`                                                                                                                                                                                                                                               |
| <data_source=cloud_cost>                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | data_source [*required*]             | enum                | Data source for Cloud Cost queries. Allowed enum values: `cloud_cost`                                                                                                                                                                                                                                                                 |
| <data_source=cloud_cost>                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=cloud_cost>                  | query [*required*]                   | string              | Query for Cloud Cost data.                                                                                                                                                                                                                                                                                                            |
| queries                                   | <data_source=product_analytics_extended>  | object              | A formula and functions Product Analytics Extended query for advanced analytics features.                                                                                                                                                                                                                                             |
| <data_source=product_analytics_extended>  | audience_filters                          | object              | Product Analytics/RUM audience filters.                                                                                                                                                                                                                                                                                               |
| audience_filters                          | accounts                                  | [object]            |
| audience_filters                          | filter_condition                          | string              | An optional filter condition applied to the audience subquery.                                                                                                                                                                                                                                                                        |
| audience_filters                          | segments                                  | [object]            |
| audience_filters                          | users                                     | [object]            |
| <data_source=product_analytics_extended>  | compute [*required*]                 | object              | Compute configuration for Product Analytics Extended queries.                                                                                                                                                                                                                                                                         |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Fixed-width time bucket interval in milliseconds for time series queries. Mutually exclusive with `rollup`.                                                                                                                                                                                                                           |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| compute                                   | name                                      | string              | Name of the compute for use in formulas.                                                                                                                                                                                                                                                                                              |
| compute                                   | rollup                                    | object              | Calendar-aligned time bucket for time series queries (for example, day, week, or month boundaries). Mutually exclusive with `interval`.                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | data_source [*required*]             | enum                | Data source for Product Analytics Extended queries. Allowed enum values: `product_analytics_extended`                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_extended>  | indexes                                   | [string]            | Event indexes to query.                                                                                                                                                                                                                                                                                                               |
| <data_source=product_analytics_extended>  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_extended>  | query [*required*]                   | object              | Base query for Product Analytics.                                                                                                                                                                                                                                                                                                     |
| query                                     | data_source [*required*]             | enum                | Data source for Product Analytics event queries. Allowed enum values: `product_analytics`                                                                                                                                                                                                                                             |
| query                                     | search [*required*]                  | object              | Search configuration for Product Analytics event query.                                                                                                                                                                                                                                                                               |
| queries                                   | <data_source=product_analytics_journey>   | object              | A formula and functions User Journey query for defining funnel, timeseries, and scalar visualizations over journey data.                                                                                                                                                                                                              |
| <data_source=product_analytics_journey>   | compute [*required*]                 | object              | Compute configuration for User Journey formula queries.                                                                                                                                                                                                                                                                               |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | double              | Time bucket interval in milliseconds for time series queries.                                                                                                                                                                                                                                                                         |
| compute                                   | metric                                    | enum                | Metric for User Journey formula compute. `__dd.conversion` and `__dd.conversion_rate` accept `count` and `cardinality` as aggregations. `__dd.time_to_convert` accepts `avg`, `median`, `pc75`, `pc95`, `pc98`, `pc99`, `min`, and `max`. Allowed enum values: `__dd.conversion,__dd.conversion_rate,__dd.time_to_convert`            |
| compute                                   | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | data_source [*required*]             | enum                | Data source for user journey funnel queries. Allowed enum values: `product_analytics_journey`                                                                                                                                                                                                                                         |
| <data_source=product_analytics_journey>   | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet name to group by.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | limit                                     | int32               | Maximum number of groups to return.                                                                                                                                                                                                                                                                                                   |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude events missing the group-by facet.                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Options for sorting group by results.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | target                                    | object              | Target for user journey search.                                                                                                                                                                                                                                                                                                       |
| <data_source=product_analytics_journey>   | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_journey>   | search [*required*]                  | object              | User journey search configuration.                                                                                                                                                                                                                                                                                                    |
| search                                    | expression [*required*]              | string              | Expression string.                                                                                                                                                                                                                                                                                                                    |
| search                                    | filters                                   | object              | Filters for user journey search.                                                                                                                                                                                                                                                                                                      |
| search                                    | join_keys                                 | object              | Join keys for user journey queries.                                                                                                                                                                                                                                                                                                   |
| search                                    | node_objects [*required*]            | object              | Node objects mapping.                                                                                                                                                                                                                                                                                                                 |
| search                                    | step_aliases                              | object              | Step aliases mapping.                                                                                                                                                                                                                                                                                                                 |
| queries                                   | <data_source=product_analytics_retention> | object              | A formula and functions Retention query for defining timeseries and scalar visualizations.                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | compute [*required*]                 | object              | Compute configuration for retention queries.                                                                                                                                                                                                                                                                                          |
| compute                                   | aggregation [*required*]             |  <oneOf>       | The type of aggregation that can be performed on events-based queries.                                                                                                                                                                                                                                                                |
| compute                                   | metric [*required*]                  | enum                | Metric for retention compute. Allowed enum values: `__dd.retention,__dd.retention_rate`                                                                                                                                                                                                                                               |
| <data_source=product_analytics_retention> | data_source [*required*]             | enum                | Data source for retention queries. Allowed enum values: `product_analytics_retention`                                                                                                                                                                                                                                                 |
| <data_source=product_analytics_retention> | group_by                                  | [object]            | Group by configuration.                                                                                                                                                                                                                                                                                                               |
| group_by                                  | facet [*required*]                   | string              | Facet to group by.                                                                                                                                                                                                                                                                                                                    |
| group_by                                  | limit                                     | int64               | Maximum number of groups.                                                                                                                                                                                                                                                                                                             |
| group_by                                  | should_exclude_missing                    | boolean             | Whether to exclude missing values.                                                                                                                                                                                                                                                                                                    |
| group_by                                  | sort                                      | object              | Sort configuration for retention group by.                                                                                                                                                                                                                                                                                            |
| group_by                                  | source                                    | string              | Source field.                                                                                                                                                                                                                                                                                                                         |
| group_by                                  | target [*required*]                  | enum                | Target for retention group by. Allowed enum values: `cohort,return_period`                                                                                                                                                                                                                                                            |
| <data_source=product_analytics_retention> | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=product_analytics_retention> | search [*required*]                  | object              | Search configuration for retention queries.                                                                                                                                                                                                                                                                                           |
| search                                    | cohort_criteria [*required*]         | object              | Cohort criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| search                                    | filters                                   | object              | Filters for retention queries.                                                                                                                                                                                                                                                                                                        |
| search                                    | retention_entity [*required*]        | enum                | Entity to track for retention. Allowed enum values: `@usr.id,@account.id`                                                                                                                                                                                                                                                             |
| search                                    | return_condition [*required*]        | enum                | Condition for counting user return. Allowed enum values: `conversion_on,conversion_on_or_after`                                                                                                                                                                                                                                       |
| search                                    | return_criteria                           | object              | Return criteria for retention queries.                                                                                                                                                                                                                                                                                                |
| requests                                  | query                                     |  <oneOf>       | Query definition for Distribution Widget Histogram Request                                                                                                                                                                                                                                                                            |
| query                                     | <data_source=metrics>                     | object              | A formula and functions metrics query.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | aggregator                                | enum                | The aggregation methods available for metrics queries. Allowed enum values: `avg,min,max,sum,last,area,l2norm,percentile`                                                                                                                                                                                                             |
| <data_source=metrics>                     | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=metrics>                     | data_source [*required*]             | enum                | Data source for metrics queries. Allowed enum values: `metrics`                                                                                                                                                                                                                                                                       |
| <data_source=metrics>                     | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=metrics>                     | query [*required*]                   | string              | Metrics query definition.                                                                                                                                                                                                                                                                                                             |
| <data_source=metrics>                     | semantic_mode                             | enum                | Semantic mode for metrics queries. This determines how metrics from different sources are combined or displayed. Allowed enum values: `combined,native`                                                                                                                                                                               |
| query                                     | Object 2                                  | object              | A formula and functions events query.                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | compute [*required*]                 | object              | Compute options.                                                                                                                                                                                                                                                                                                                      |
| compute                                   | aggregation [*required*]             | enum                | Aggregation methods for event platform queries. Allowed enum values: `count,cardinality,median,pc75,pc90,pc95,pc98,pc99,sum,min`                                                                                                                                                                                                      |
| compute                                   | interval                                  | int64               | A time interval in milliseconds.                                                                                                                                                                                                                                                                                                      |
| compute                                   | metric                                    | string              | Measurable attribute to compute.                                                                                                                                                                                                                                                                                                      |
| Object 2                                  | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| Object 2                                  | data_source [*required*]             | enum                | Data source for event platform-based queries. Allowed enum values: `logs,spans,network,rum,security_signals,profiles,audit,events,ci_tests,ci_pipelines`                                                                                                                                                                              |
| Object 2                                  | group_by                                  |  <oneOf>       | Group by configuration for a formula and functions events query. Accepts either a list of facet objects or a flat object that specifies a list of facet fields.                                                                                                                                                                       |
| group_by                                  | Object 1                                  | [object]            | List of objects used to group by.                                                                                                                                                                                                                                                                                                     |
| group_by                                  | Object 2                                  | object              | Flat group by configuration using multiple event facet fields.                                                                                                                                                                                                                                                                        |
| Object 2                                  | indexes                                   | [string]            | An array of index names to query in the stream. Omit or use `[]` to query all indexes at once.                                                                                                                                                                                                                                        |
| Object 2                                  | name [*required*]                    | string              | Name of the query for use in formulas.                                                                                                                                                                                                                                                                                                |
| Object 2                                  | search                                    | object              | Search options.                                                                                                                                                                                                                                                                                                                       |
| search                                    | query [*required*]                   | string              | Events search string.                                                                                                                                                                                                                                                                                                                 |
| Object 2                                  | storage                                   | string              | Option for storage location. Feature in Private Beta.                                                                                                                                                                                                                                                                                 |
| query                                     | <data_source=apm_resource_stats>          | object              | **DEPRECATED**: APM resource stats query using formulas and functions. Deprecated - Use `apm_metrics` query type instead.                                                                                                                                                                                                             |
| <data_source=apm_resource_stats>          | cross_org_uuids                           | [string]            | The source organization UUID for cross organization queries. Feature in Private Beta.                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | data_source [*required*]             | enum                | Data source for APM resource stats queries. Allowed enum values: `apm_resource_stats`                                                                                                                                                                                                                                                 |
| <data_source=apm_resource_stats>          | env [*required*]                     | string              | APM environment.                                                                                                                                                                                                                                                                                                                      |
| <data_source=apm_resource_stats>          | group_by                                  | [string]            | Array of fields to group results by.                                                                                                                                                                                                                                                                                                  |
| <data_source=apm_resource_stats>          | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_resource_stats>          | operation_name                            | string              | Name of operation on service.                                                                                                                                                                                                                                                                                                         |
| <data_source=apm_resource_stats>          | primary_tag_name                          | string              | Name of the second primary tag used within APM. Required when `primary_tag_value` is specified. See [https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope/#add-a-second-primary-tag-in-datadog](https://docs.datadoghq.com/tracing/guide/setting_primary_tags_to_scope.md#add-a-second-primary-tag-in-datadog)      |
| <data_source=apm_resource_stats>          | primary_tag_value                         | string              | Value of the second primary tag by which to filter APM data. `primary_tag_name` must also be specified.                                                                                                                                                                                                                               |
| <data_source=apm_resource_stats>          | resource_name                             | string              | APM resource name.                                                                                                                                                                                                                                                                                                                    |
| <data_source=apm_resource_stats>          | service [*required*]                 | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_resource_stats>          | stat [*required*]                    | enum                | APM resource stat name. Allowed enum values: `errors,error_rate,hits,latency_avg,latency_distribution,latency_max,latency_p50,latency_p75,latency_p90,latency_p95`                                                                                                                                                                    |
| query                                     | <data_source=apm_metrics>                 | object              | A formula and functions APM metrics query.                                                                                                                                                                                                                                                                                            |
| <data_source=apm_metrics>                 | data_source [*required*]             | enum                | Data source for APM metrics queries. Allowed enum values: `apm_metrics`                                                                                                                                                                                                                                                               |
| <data_source=apm_metrics>                 | group_by                                  | [string]            | Optional fields to group the query results by.                                                                                                                                                                                                                                                                                        |
| <data_source=apm_metrics>                 | name [*required*]                    | string              | Name of this query to use in formulas.                                                                                                                                                                                                                                                                                                |
| <data_source=apm_metrics>                 | operation_mode                            | string              | Optional operation mode to aggregate across operation names.                                                                                                                                                                                                                                                                          |
| <data_source=apm_metrics>                 | operation_name                            | string              | Name of operation on service. If not provided, the primary operation name is used.                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | peer_tags                                 | [string]            | Tags to query for a specific downstream entity (peer.service, peer.db_instance, peer.s3, peer.s3.bucket, etc.).                                                                                                                                                                                                                       |
| <data_source=apm_metrics>                 | query_filter                              | string              | Additional filters for the query using metrics query syntax (e.g., env, primary_tag).                                                                                                                                                                                                                                                 |
| <data_source=apm_metrics>                 | resource_hash                             | string              | The hash of a specific resource to filter by.                                                                                                                                                                                                                                                                                         |
| <data_source=apm_metrics>                 | resource_name                             | string              | The full name of a specific resource to filter by.                                                                                                                                                                                                                                                                                    |
| <data_source=apm_metrics>                 | service                                   | string              | APM service name.                                                                                                                                                                                                                                                                                                                     |
| <data_source=apm_metrics>                 | span_kind                                 | enum                | Describes the relationship between the span, its parents, and its children in a trace. Allowed enum values: `consumer,server,client,producer,internal`                                                                                                                                                                                |
| <data_source=apm_metrics>                 | stat [*required*]                    | enum                | APM metric stat name. Allowed enum values: `errors,error_rate,errors_per_second,latency_avg,latency_max,latency_p50,latency_p75,latency_p90,latency_p95,latency_p99`                                                                                                                                                                  |
| requests                                  | request_type                              | enum                | Distribution of point values for distribution metrics. Renders a histogram of raw metric data points. Allowed enum values: `histogram`                                                                                                                                                                                                |
| requests                                  | response_format                           | enum                | Distribution of aggregated grouped queries. Use `request_type` instead for distribution of point values from distribution metrics. Allowed enum values: `timeseries,scalar,event_list`                                                                                                                                                |
| requests                                  | rum_query                                 | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| rum_query                                 | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| rum_query                                 | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| rum_query                                 | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| rum_query                                 | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | security_query                            | object              | **DEPRECATED**: Deprecated - Use `queries` and `formulas` instead.                                                                                                                                                                                                                                                                    |
| security_query                            | compute                                   | object              | Define computation for a log query.                                                                                                                                                                                                                                                                                                   |
| compute                                   | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| compute                                   | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| compute                                   | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | group_by                                  | [object]            | List of tag prefixes to group by in the case of a cluster check.                                                                                                                                                                                                                                                                      |
| group_by                                  | facet [*required*]                   | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| group_by                                  | limit                                     | int64               | Maximum number of items in the group.                                                                                                                                                                                                                                                                                                 |
| group_by                                  | sort                                      | object              | Define a sorting method.                                                                                                                                                                                                                                                                                                              |
| sort                                      | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| sort                                      | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| security_query                            | index                                     | string              | A coma separated-list of index names. Use "*" query all indexes at once. [Multiple Indexes](https://docs.datadoghq.com/logs/indexes.md#multiple-indexes)                                                                                                                                                                              |
| security_query                            | multi_compute                             | [object]            | This field is mutually exclusive with `compute`.                                                                                                                                                                                                                                                                                      |
| multi_compute                             | aggregation [*required*]             | string              | The aggregation method.                                                                                                                                                                                                                                                                                                               |
| multi_compute                             | facet                                     | string              | Facet name.                                                                                                                                                                                                                                                                                                                           |
| multi_compute                             | interval                                  | int64               | Define a time interval in seconds.                                                                                                                                                                                                                                                                                                    |
| security_query                            | search                                    | object              | The query being made on the logs.                                                                                                                                                                                                                                                                                                     |
| search                                    | query [*required*]                   | string              | Search value to apply.                                                                                                                                                                                                                                                                                                                |
| requests                                  | style                                     | object              | Widget style definition.                                                                                                                                                                                                                                                                                                              |
| style                                     | palette                                   | string              | Color palette to apply to the widget.                                                                                                                                                                                                                                                                                                 |
| definition                                | show_legend                               | boolean             | **DEPRECATED**: (Deprecated) The widget legend was replaced by a tooltip and sidebar.                                                                                                                                                                                                                                                 |
| definition                                | time                                      |  <oneOf>       | Time setting for the widget.                                                                                                                                                                                                                                                                                                          |
| time                                      | Object 1                                  | object              | Wrapper for live span                                                                                                                                                                                                                                                                                                                 |
| Object 1                                  | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span                                 | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | <type=live>                               | object              | Used for arbitrary live span times, such as 17 minutes or 6 hours.                                                                                                                                                                                                                                                                    |
| <type=live>                               | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=live>                               | type [*required*]                    | enum                | Type "live" denotes a live span in the new format. Allowed enum values: `live`                                                                                                                                                                                                                                                        |
| <type=live>                               | unit [*required*]                    | enum                | Unit of the time span. Allowed enum values: `minute,hour,day,week,month,year`                                                                                                                                                                                                                                                         |
| <type=live>                               | value [*required*]                   | int64               | Value of the time span.                                                                                                                                                                                                                                                                                                               |
| time                                      | <type=fixed>                              | object              | Used for fixed span times, such as 'March 1 to March 7'.                                                                                                                                                                                                                                                                              |
| <type=fixed>                              | from [*required*]                    | int64               | Start time in milliseconds since epoch.                                                                                                                                                                                                                                                                                               |
| <type=fixed>                              | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=fixed>                              | to [*required*]                      | int64               | End time in milliseconds since epoch.                                                                                                                                                                                                                                                                                                 |
| <type=fixed>                              | type [*required*]                    | enum                | Type "fixed" denotes a fixed span. Allowed enum values: `fixed`                                                                                                                                                                                                                                                                       |
| definition                                | title                                     | string              | Title of the widget.                                                                                                                                                                                                                                                                                                                  |
| definition                                | title_align                               | enum                | How to align the text on the widget. Allowed enum values: `center,left,right`                                                                                                                                                                                                                                                         |
| definition                                | title_size                                | string              | Size of the title.                                                                                                                                                                                                                                                                                                                    |
| definition                                | type [*required*]                    | enum                | Type of the distribution widget. Allowed enum values: `distribution`                                                                                                                                                                                                                                                                  |
| definition                                | xaxis                                     | object              | X Axis controls for the distribution widget.                                                                                                                                                                                                                                                                                          |
| xaxis                                     | include_zero                              | boolean             | True includes zero.                                                                                                                                                                                                                                                                                                                   |
| xaxis                                     | max                                       | string              | Specifies maximum value to show on the x-axis. It takes a number, percentile (p90 === 90th percentile), or auto for default behavior.                                                                                                                                                                                                 |
| xaxis                                     | min                                       | string              | Specifies minimum value to show on the x-axis. It takes a number, percentile (p90 === 90th percentile), or auto for default behavior.                                                                                                                                                                                                 |
| xaxis                                     | num_buckets                               | int64               | Number of value buckets to target, also known as the resolution of the value bins.                                                                                                                                                                                                                                                    |
| xaxis                                     | scale                                     | string              | Specifies the scale type. Possible values are `linear`.                                                                                                                                                                                                                                                                               |
| definition                                | yaxis                                     | object              | Y Axis controls for the distribution widget.                                                                                                                                                                                                                                                                                          |
| yaxis                                     | include_zero                              | boolean             | True includes zero.                                                                                                                                                                                                                                                                                                                   |
| yaxis                                     | label                                     | string              | The label of the axis to display on the graph.                                                                                                                                                                                                                                                                                        |
| yaxis                                     | max                                       | string              | Specifies the maximum value to show on the y-axis. It takes a number, or auto for default behavior.                                                                                                                                                                                                                                   |
| yaxis                                     | min                                       | string              | Specifies minimum value to show on the y-axis. It takes a number, or auto for default behavior.                                                                                                                                                                                                                                       |
| yaxis                                     | scale                                     | string              | Specifies the scale type. Possible values are `linear` or `log`.                                                                                                                                                                                                                                                                      |
| Object 5                                  | graph_size                                | enum                | The size of the graph. Allowed enum values: `xs,s,m,l,xl`                                                                                                                                                                                                                                                                             |
| Object 5                                  | split_by                                  | object              | Object describing how to split the graph to display multiple visualizations per request.                                                                                                                                                                                                                                              |
| split_by                                  | keys [*required*]                    | [string]            | Keys to split on.                                                                                                                                                                                                                                                                                                                     |
| split_by                                  | tags [*required*]                    | [string]            | Tags to split on.                                                                                                                                                                                                                                                                                                                     |
| Object 5                                  | time                                      | object <oneOf> | Timeframe for the notebook cell. When 'null', the notebook global time is used.                                                                                                                                                                                                                                                       |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| attributes                                | Object 6                                  | object              | The attributes of a notebook `log_stream` cell.                                                                                                                                                                                                                                                                                       |
| Object 6                                  | definition [*required*]              | object              | The Log Stream displays a log flow matching the defined query.                                                                                                                                                                                                                                                                        |
| definition                                | columns                                   | [string]            | Which columns to display on the widget.                                                                                                                                                                                                                                                                                               |
| definition                                | description                               | string              | The description of the widget.                                                                                                                                                                                                                                                                                                        |
| definition                                | indexes                                   | [string]            | An array of index names to query in the stream. Use [] to query all indexes at once.                                                                                                                                                                                                                                                  |
| definition                                | logset                                    | string              | **DEPRECATED**: ID of the log set to use.                                                                                                                                                                                                                                                                                             |
| definition                                | message_display                           | enum                | Amount of log lines to display Allowed enum values: `inline,expanded-md,expanded-lg`                                                                                                                                                                                                                                                  |
| definition                                | query                                     | string              | Query to filter the log stream with.                                                                                                                                                                                                                                                                                                  |
| definition                                | show_date_column                          | boolean             | Whether to show the date column or not                                                                                                                                                                                                                                                                                                |
| definition                                | show_message_column                       | boolean             | Whether to show the message column or not                                                                                                                                                                                                                                                                                             |
| definition                                | sort                                      | object              | Which column and order to sort by                                                                                                                                                                                                                                                                                                     |
| sort                                      | column [*required*]                  | string              | Facet path for the column                                                                                                                                                                                                                                                                                                             |
| sort                                      | order [*required*]                   | enum                | Widget sorting methods. Allowed enum values: `asc,desc`                                                                                                                                                                                                                                                                               |
| definition                                | time                                      |  <oneOf>       | Time setting for the widget.                                                                                                                                                                                                                                                                                                          |
| time                                      | Object 1                                  | object              | Wrapper for live span                                                                                                                                                                                                                                                                                                                 |
| Object 1                                  | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span                                 | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | <type=live>                               | object              | Used for arbitrary live span times, such as 17 minutes or 6 hours.                                                                                                                                                                                                                                                                    |
| <type=live>                               | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=live>                               | type [*required*]                    | enum                | Type "live" denotes a live span in the new format. Allowed enum values: `live`                                                                                                                                                                                                                                                        |
| <type=live>                               | unit [*required*]                    | enum                | Unit of the time span. Allowed enum values: `minute,hour,day,week,month,year`                                                                                                                                                                                                                                                         |
| <type=live>                               | value [*required*]                   | int64               | Value of the time span.                                                                                                                                                                                                                                                                                                               |
| time                                      | <type=fixed>                              | object              | Used for fixed span times, such as 'March 1 to March 7'.                                                                                                                                                                                                                                                                              |
| <type=fixed>                              | from [*required*]                    | int64               | Start time in milliseconds since epoch.                                                                                                                                                                                                                                                                                               |
| <type=fixed>                              | hide_incomplete_cost_data                 | boolean             | Whether to hide incomplete cost data in the widget.                                                                                                                                                                                                                                                                                   |
| <type=fixed>                              | to [*required*]                      | int64               | End time in milliseconds since epoch.                                                                                                                                                                                                                                                                                                 |
| <type=fixed>                              | type [*required*]                    | enum                | Type "fixed" denotes a fixed span. Allowed enum values: `fixed`                                                                                                                                                                                                                                                                       |
| definition                                | title                                     | string              | Title of the widget.                                                                                                                                                                                                                                                                                                                  |
| definition                                | title_align                               | enum                | How to align the text on the widget. Allowed enum values: `center,left,right`                                                                                                                                                                                                                                                         |
| definition                                | title_size                                | string              | Size of the title.                                                                                                                                                                                                                                                                                                                    |
| definition                                | type [*required*]                    | enum                | Type of the log stream widget. Allowed enum values: `log_stream`                                                                                                                                                                                                                                                                      |
| Object 6                                  | graph_size                                | enum                | The size of the graph. Allowed enum values: `xs,s,m,l,xl`                                                                                                                                                                                                                                                                             |
| Object 6                                  | time                                      | object <oneOf> | Timeframe for the notebook cell. When 'null', the notebook global time is used.                                                                                                                                                                                                                                                       |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| cells                                     | id [*required*]                      | string              | Notebook cell ID.                                                                                                                                                                                                                                                                                                                     |
| cells                                     | type [*required*]                    | enum                | Type of the Notebook Cell resource. Allowed enum values: `notebook_cells`                                                                                                                                                                                                                                                             |
| attributes                                | created                                   | date-time           | UTC time stamp for when the notebook was created.                                                                                                                                                                                                                                                                                     |
| attributes                                | metadata                                  | object              | Metadata associated with the notebook.                                                                                                                                                                                                                                                                                                |
| metadata                                  | is_template                               | boolean             | Whether or not the notebook is a template.                                                                                                                                                                                                                                                                                            |
| metadata                                  | take_snapshots                            | boolean             | Whether or not the notebook takes snapshot image backups of the notebook's fixed-time graphs.                                                                                                                                                                                                                                         |
| metadata                                  | type                                      | enum                | Metadata type of the notebook. Allowed enum values: `postmortem,runbook,investigation,documentation,report`                                                                                                                                                                                                                           |
| attributes                                | modified                                  | date-time           | UTC time stamp for when the notebook was last modified.                                                                                                                                                                                                                                                                               |
| attributes                                | name [*required*]                    | string              | The name of the notebook.                                                                                                                                                                                                                                                                                                             |
| attributes                                | status                                    | enum                | Publication status of the notebook. For now, always "published". Allowed enum values: `published`                                                                                                                                                                                                                                     |
| attributes                                | template_variables                        | [object]            | List of template variables for this notebook.                                                                                                                                                                                                                                                                                         |
| template_variables                        | available_values                          | [string]            | The list of values that the template variable drop-down is limited to.                                                                                                                                                                                                                                                                |
| template_variables                        | available_values_query                    |  <oneOf>       | Query used to dynamically populate the list of available values for the template variable.                                                                                                                                                                                                                                            |
| available_values_query                    | Object 1                                  | object              | Available values query for logs, RUM, or spans data sources.                                                                                                                                                                                                                                                                          |
| Object 1                                  | data_source [*required*]             | string              | The data source for the query. Must be one of `logs`, `rum`, or `spans`.                                                                                                                                                                                                                                                              |
| Object 1                                  | group_by [*required*]                | [object]            | Group-by fields for the query.                                                                                                                                                                                                                                                                                                        |
| group_by                                  | facet [*required*]                   | string              | The facet name to group by.                                                                                                                                                                                                                                                                                                           |
| Object 1                                  | search [*required*]                  | object              | Search parameters for an available values query.                                                                                                                                                                                                                                                                                      |
| search                                    | query [*required*]                   | string              | The search query string.                                                                                                                                                                                                                                                                                                              |
| available_values_query                    | Object 2                                  | object              | Available values query for the metrics data source.                                                                                                                                                                                                                                                                                   |
| Object 2                                  | data_source [*required*]             | string              | The data source for the query. Must be `metrics`.                                                                                                                                                                                                                                                                                     |
| Object 2                                  | query [*required*]                   | string              | The metrics query string.                                                                                                                                                                                                                                                                                                             |
| template_variables                        | data_source_mappings                      | object              | Mapping of data source names to template variable values.                                                                                                                                                                                                                                                                             |
| additionalProperties                      | <any-key>                                 | string              | The value for the given data source.                                                                                                                                                                                                                                                                                                  |
| template_variables                        | default                                   | string              | **DEPRECATED**: (deprecated) The default value for the template variable on notebook load. Cannot be used in conjunction with `defaults`.                                                                                                                                                                                             |
| template_variables                        | defaults                                  | [string]            | One or many default values for the template variable. Cannot be used in conjunction with `default`.                                                                                                                                                                                                                                   |
| template_variables                        | name [*required*]                    | string              | The name of the variable.                                                                                                                                                                                                                                                                                                             |
| template_variables                        | placement                                 | string              | The placement of the template variable in the notebook.                                                                                                                                                                                                                                                                               |
| template_variables                        | prefix                                    | string              | The tag prefix associated with the variable. Only tags with this prefix appear in the variable drop-down.                                                                                                                                                                                                                             |
| template_variables                        | type                                      | string              | The type of the template variable.                                                                                                                                                                                                                                                                                                    |
| attributes                                | time [*required*]                    |  <oneOf>       | Notebook global timeframe.                                                                                                                                                                                                                                                                                                            |
| time                                      | Object 1                                  | object              | Relative timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 1                                  | live_span [*required*]               | enum                | The available timeframes depend on the widget you are using. Allowed enum values: `1m,5m,10m,15m,30m,1h,4h,1d,2d,1w`                                                                                                                                                                                                                  |
| time                                      | Object 2                                  | object              | Absolute timeframe.                                                                                                                                                                                                                                                                                                                   |
| Object 2                                  | end [*required*]                     | date-time           | The end time.                                                                                                                                                                                                                                                                                                                         |
| Object 2                                  | live                                      | boolean             | Indicates whether the timeframe should be shifted to end at the current time.                                                                                                                                                                                                                                                         |
| Object 2                                  | start [*required*]                   | date-time           | The start time.                                                                                                                                                                                                                                                                                                                       |
| data                                      | id [*required*]                      | int64               | Unique notebook ID, assigned when you create the notebook.                                                                                                                                                                                                                                                                            |
| data                                      | type [*required*]                    | enum                | Type of the Notebook resource. Allowed enum values: `notebooks`                                                                                                                                                                                                                                                                       |

{% /tab %}

{% tab title="Example" %}

```json
{
  "data": {
    "attributes": {
      "author": {
        "created_at": "2019-09-19T10:00:00.000Z",
        "disabled": false,
        "email": "string",
        "handle": "string",
        "icon": "string",
        "name": "string",
        "status": "string",
        "title": "string",
        "verified": false
      },
      "cells": [
        {
          "attributes": {
            "definition": {
              "requests": [
                {
                  "display_type": "line",
                  "q": "avg:system.load.1{*}",
                  "style": {
                    "line_type": "solid",
                    "line_width": "normal",
                    "palette": "dog_classic"
                  }
                }
              ],
              "show_legend": true,
              "type": "timeseries",
              "yaxis": {
                "scale": "linear"
              }
            },
            "graph_size": "m",
            "split_by": {
              "keys": [],
              "tags": []
            },
            "time": null
          },
          "id": "abcd1234",
          "type": "notebook_cells"
        }
      ],
      "created": "2021-02-24T23:14:15.173964+00:00",
      "metadata": {
        "is_template": false,
        "take_snapshots": false,
        "type": "investigation"
      },
      "modified": "2021-02-24T23:15:23.274966+00:00",
      "name": "Example Notebook",
      "status": "published",
      "template_variables": [
        {
          "available_values": [
            "my-host",
            "host1",
            "host2"
          ],
          "available_values_query": {
            "data_source": "logs",
            "group_by": [
              {
                "facet": "host"
              }
            ],
            "search": {
              "query": "service:web"
            }
          },
          "data_source_mappings": {
            "<any-key>": "string"
          },
          "default": "my-host",
          "defaults": [
            "my-host-1",
            "my-host-2"
          ],
          "name": "host1",
          "placement": "global",
          "prefix": "host",
          "type": "tag"
        }
      ],
      "time": {
        "live_span": "5m"
      }
    },
    "id": 123456,
    "type": "notebooks"
  }
}
```

{% /tab %}

{% /tab %}

{% tab title="400" %}
Bad Request
{% tab title="Model" %}
Error response object.

| Field                    | Type     | Description                          |
| ------------------------ | -------- | ------------------------------------ |
| errors [*required*] | [string] | Array of errors returned by the API. |

{% /tab %}

{% tab title="Example" %}

```json
{
  "errors": [
    "Bad Request"
  ]
}
```

{% /tab %}

{% /tab %}

{% tab title="403" %}
Authentication Error
{% tab title="Model" %}
Error response object.

| Field                    | Type     | Description                          |
| ------------------------ | -------- | ------------------------------------ |
| errors [*required*] | [string] | Array of errors returned by the API. |

{% /tab %}

{% tab title="Example" %}

```json
{
  "errors": [
    "Bad Request"
  ]
}
```

{% /tab %}

{% /tab %}

{% tab title="429" %}
Too many requests
{% tab title="Model" %}
Error response object.

| Field                    | Type     | Description                          |
| ------------------------ | -------- | ------------------------------------ |
| errors [*required*] | [string] | Array of errors returned by the API. |

{% /tab %}

{% tab title="Example" %}

```json
{
  "errors": [
    "Bad Request"
  ]
}
```

{% /tab %}

{% /tab %}

### Code Example

##### 
                          \## default
# 
 \# Curl command curl -X POST "https://api.datadoghq.com/api/v1/notebooks" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "DD-API-KEY: ${DD_API_KEY}" \
-H "DD-APPLICATION-KEY: ${DD_APP_KEY}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "cells": [
        {
          "attributes": {
            "definition": {
              "text": "## Some test markdown\n\nWith some example content.",
              "type": "markdown"
            }
          },
          "type": "notebook_cells"
        },
        {
          "attributes": {
            "definition": {
              "requests": [
                {
                  "display_type": "line",
                  "q": "avg:system.load.1{*}",
                  "style": {
                    "line_type": "solid",
                    "line_width": "normal",
                    "palette": "dog_classic"
                  }
                }
              ],
              "show_legend": true,
              "type": "timeseries",
              "yaxis": {
                "scale": "linear"
              }
            },
            "graph_size": "m",
            "split_by": {
              "keys": [],
              "tags": []
            },
            "time": null
          },
          "type": "notebook_cells"
        }
      ],
      "name": "Example Notebook",
      "time": {
        "live_span": "1h"
      }
    },
    "type": "notebooks"
  }
}
EOF \## json-request-body
# 
 \# Curl command curl -X POST "https://api.datadoghq.com/api/v1/notebooks" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "DD-API-KEY: ${DD_API_KEY}" \
-H "DD-APPLICATION-KEY: ${DD_APP_KEY}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "cells": [
        {
          "attributes": {
            "definition": {
              "text": "## Some test markdown\n\nWith some example content.",
              "type": "markdown"
            }
          },
          "type": "notebook_cells"
        },
        {
          "attributes": {
            "definition": {
              "requests": [
                {
                  "display_type": "line",
                  "q": "avg:system.load.1{*}",
                  "style": {
                    "line_type": "solid",
                    "line_width": "normal",
                    "palette": "dog_classic"
                  }
                }
              ],
              "show_legend": true,
              "type": "timeseries",
              "yaxis": {
                "scale": "linear"
              }
            },
            "graph_size": "m",
            "split_by": {
              "keys": [],
              "tags": []
            },
            "time": null
          },
          "type": "notebook_cells"
        }
      ],
      "name": "Example Notebook",
      "time": {
        "live_span": "1h"
      }
    },
    "type": "notebooks"
  }
}
EOF 
                        
##### 

````go
// Create a notebook returns "OK" response

package main

import (
	"context"
	"encoding/json"
	"fmt"
	"os"

	"github.com/DataDog/datadog-api-client-go/v2/api/datadog"
	"github.com/DataDog/datadog-api-client-go/v2/api/datadogV1"
)

func main() {
	body := datadogV1.NotebookCreateRequest{
		Data: datadogV1.NotebookCreateData{
			Attributes: datadogV1.NotebookCreateDataAttributes{
				Cells: []datadogV1.NotebookCellCreateRequest{
					{
						Attributes: datadogV1.NotebookCellCreateRequestAttributes{
							NotebookMarkdownCellAttributes: &datadogV1.NotebookMarkdownCellAttributes{
								Definition: datadogV1.NotebookMarkdownCellDefinition{
									Text: `## Some test markdown

` + "```" + `
var x, y;
x = 5;
y = 6;
` + "```",
									Type: datadogV1.NOTEBOOKMARKDOWNCELLDEFINITIONTYPE_MARKDOWN,
								},
							}},
						Type: datadogV1.NOTEBOOKCELLRESOURCETYPE_NOTEBOOK_CELLS,
					},
					{
						Attributes: datadogV1.NotebookCellCreateRequestAttributes{
							NotebookTimeseriesCellAttributes: &datadogV1.NotebookTimeseriesCellAttributes{
								Definition: datadogV1.TimeseriesWidgetDefinition{
									Requests: []datadogV1.TimeseriesWidgetRequest{
										{
											DisplayType: datadogV1.WIDGETDISPLAYTYPE_LINE.Ptr(),
											Q:           datadog.PtrString("avg:system.load.1{*}"),
											Style: &datadogV1.TimeseriesRequestStyle{
												LineType:  datadogV1.WIDGETLINETYPE_SOLID.Ptr(),
												LineWidth: datadogV1.WIDGETLINEWIDTH_NORMAL.Ptr(),
												Palette:   datadog.PtrString("dog_classic"),
											},
										},
									},
									ShowLegend: datadog.PtrBool(true),
									Type:       datadogV1.TIMESERIESWIDGETDEFINITIONTYPE_TIMESERIES,
									Yaxis: &datadogV1.WidgetAxis{
										Scale: datadog.PtrString("linear"),
									},
								},
								GraphSize: datadogV1.NOTEBOOKGRAPHSIZE_MEDIUM.Ptr(),
								SplitBy: &datadogV1.NotebookSplitBy{
									Keys: []string{},
									Tags: []string{},
								},
								Time: *datadogV1.NewNullableNotebookCellTime(nil),
							}},
						Type: datadogV1.NOTEBOOKCELLRESOURCETYPE_NOTEBOOK_CELLS,
					},
				},
				Name:   "Example-Notebook",
				Status: datadogV1.NOTEBOOKSTATUS_PUBLISHED.Ptr(),
				Time: datadogV1.NotebookGlobalTime{
					NotebookRelativeTime: &datadogV1.NotebookRelativeTime{
						LiveSpan: datadogV1.WIDGETLIVESPAN_PAST_ONE_HOUR,
					}},
			},
			Type: datadogV1.NOTEBOOKRESOURCETYPE_NOTEBOOKS,
		},
	}
	ctx := datadog.NewDefaultContext(context.Background())
	configuration := datadog.NewConfiguration()
	apiClient := datadog.NewAPIClient(configuration)
	api := datadogV1.NewNotebooksApi(apiClient)
	resp, r, err := api.CreateNotebook(ctx, body)

	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `NotebooksApi.CreateNotebook`: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}

	responseContent, _ := json.MarshalIndent(resp, "", "  ")
	fmt.Fprintf(os.Stdout, "Response from `NotebooksApi.CreateNotebook`:\n%s\n", responseContent)
}
````

#### Instructions

First [install the library and its dependencies](https://docs.datadoghq.com/api/latest.md?code-lang=go) and then save the example to `main.go` and run following commands:
    DD_SITE="datadoghq.com" DD_API_KEY="<API-KEY>" DD_APP_KEY="<APP-KEY>" go run "main.go"
##### 

````java
// Create a notebook returns "OK" response

import com.datadog.api.client.ApiClient;
import com.datadog.api.client.ApiException;
import com.datadog.api.client.v1.api.NotebooksApi;
import com.datadog.api.client.v1.model.NotebookCellCreateRequest;
import com.datadog.api.client.v1.model.NotebookCellCreateRequestAttributes;
import com.datadog.api.client.v1.model.NotebookCellResourceType;
import com.datadog.api.client.v1.model.NotebookCreateData;
import com.datadog.api.client.v1.model.NotebookCreateDataAttributes;
import com.datadog.api.client.v1.model.NotebookCreateRequest;
import com.datadog.api.client.v1.model.NotebookGlobalTime;
import com.datadog.api.client.v1.model.NotebookGraphSize;
import com.datadog.api.client.v1.model.NotebookMarkdownCellAttributes;
import com.datadog.api.client.v1.model.NotebookMarkdownCellDefinition;
import com.datadog.api.client.v1.model.NotebookMarkdownCellDefinitionType;
import com.datadog.api.client.v1.model.NotebookRelativeTime;
import com.datadog.api.client.v1.model.NotebookResourceType;
import com.datadog.api.client.v1.model.NotebookResponse;
import com.datadog.api.client.v1.model.NotebookSplitBy;
import com.datadog.api.client.v1.model.NotebookStatus;
import com.datadog.api.client.v1.model.NotebookTimeseriesCellAttributes;
import com.datadog.api.client.v1.model.TimeseriesRequestStyle;
import com.datadog.api.client.v1.model.TimeseriesWidgetDefinition;
import com.datadog.api.client.v1.model.TimeseriesWidgetDefinitionType;
import com.datadog.api.client.v1.model.TimeseriesWidgetRequest;
import com.datadog.api.client.v1.model.WidgetAxis;
import com.datadog.api.client.v1.model.WidgetDisplayType;
import com.datadog.api.client.v1.model.WidgetLineType;
import com.datadog.api.client.v1.model.WidgetLineWidth;
import com.datadog.api.client.v1.model.WidgetLiveSpan;
import java.util.Arrays;
import java.util.Collections;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = ApiClient.getDefaultApiClient();
    NotebooksApi apiInstance = new NotebooksApi(defaultClient);

    NotebookCreateRequest body =
        new NotebookCreateRequest()
            .data(
                new NotebookCreateData()
                    .attributes(
                        new NotebookCreateDataAttributes()
                            .cells(
                                Arrays.asList(
                                    new NotebookCellCreateRequest()
                                        .attributes(
                                            new NotebookCellCreateRequestAttributes(
                                                new NotebookMarkdownCellAttributes()
                                                    .definition(
                                                        new NotebookMarkdownCellDefinition()
                                                            .text(
                                                                """
## Some test markdown

```
var x, y;
x = 5;
y = 6;
```
""")
                                                            .type(
                                                                NotebookMarkdownCellDefinitionType
                                                                    .MARKDOWN))))
                                        .type(NotebookCellResourceType.NOTEBOOK_CELLS),
                                    new NotebookCellCreateRequest()
                                        .attributes(
                                            new NotebookCellCreateRequestAttributes(
                                                new NotebookTimeseriesCellAttributes()
                                                    .definition(
                                                        new TimeseriesWidgetDefinition()
                                                            .requests(
                                                                Collections.singletonList(
                                                                    new TimeseriesWidgetRequest()
                                                                        .displayType(
                                                                            WidgetDisplayType.LINE)
                                                                        .q("avg:system.load.1{*}")
                                                                        .style(
                                                                            new TimeseriesRequestStyle()
                                                                                .lineType(
                                                                                    WidgetLineType
                                                                                        .SOLID)
                                                                                .lineWidth(
                                                                                    WidgetLineWidth
                                                                                        .NORMAL)
                                                                                .palette(
                                                                                    "dog_classic"))))
                                                            .showLegend(true)
                                                            .type(
                                                                TimeseriesWidgetDefinitionType
                                                                    .TIMESERIES)
                                                            .yaxis(
                                                                new WidgetAxis().scale("linear")))
                                                    .graphSize(NotebookGraphSize.MEDIUM)
                                                    .splitBy(new NotebookSplitBy())
                                                    .time(null)))
                                        .type(NotebookCellResourceType.NOTEBOOK_CELLS)))
                            .name("Example-Notebook")
                            .status(NotebookStatus.PUBLISHED)
                            .time(
                                new NotebookGlobalTime(
                                    new NotebookRelativeTime()
                                        .liveSpan(WidgetLiveSpan.PAST_ONE_HOUR))))
                    .type(NotebookResourceType.NOTEBOOKS));

    try {
      NotebookResponse result = apiInstance.createNotebook(body);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling NotebooksApi#createNotebook");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}
````

#### Instructions

First [install the library and its dependencies](https://docs.datadoghq.com/api/latest.md?code-lang=java) and then save the example to `Example.java` and run following commands:
    DD_SITE="datadoghq.com" DD_API_KEY="<API-KEY>" DD_APP_KEY="<APP-KEY>" java "Example.java"
##### 

````python
"""
Create a notebook returns "OK" response
"""

from datadog_api_client import ApiClient, Configuration
from datadog_api_client.v1.api.notebooks_api import NotebooksApi
from datadog_api_client.v1.model.notebook_cell_create_request import NotebookCellCreateRequest
from datadog_api_client.v1.model.notebook_cell_resource_type import NotebookCellResourceType
from datadog_api_client.v1.model.notebook_create_data import NotebookCreateData
from datadog_api_client.v1.model.notebook_create_data_attributes import NotebookCreateDataAttributes
from datadog_api_client.v1.model.notebook_create_request import NotebookCreateRequest
from datadog_api_client.v1.model.notebook_graph_size import NotebookGraphSize
from datadog_api_client.v1.model.notebook_markdown_cell_attributes import NotebookMarkdownCellAttributes
from datadog_api_client.v1.model.notebook_markdown_cell_definition import NotebookMarkdownCellDefinition
from datadog_api_client.v1.model.notebook_markdown_cell_definition_type import NotebookMarkdownCellDefinitionType
from datadog_api_client.v1.model.notebook_relative_time import NotebookRelativeTime
from datadog_api_client.v1.model.notebook_resource_type import NotebookResourceType
from datadog_api_client.v1.model.notebook_split_by import NotebookSplitBy
from datadog_api_client.v1.model.notebook_status import NotebookStatus
from datadog_api_client.v1.model.notebook_timeseries_cell_attributes import NotebookTimeseriesCellAttributes
from datadog_api_client.v1.model.timeseries_request_style import TimeseriesRequestStyle
from datadog_api_client.v1.model.timeseries_widget_definition import TimeseriesWidgetDefinition
from datadog_api_client.v1.model.timeseries_widget_definition_type import TimeseriesWidgetDefinitionType
from datadog_api_client.v1.model.timeseries_widget_request import TimeseriesWidgetRequest
from datadog_api_client.v1.model.widget_axis import WidgetAxis
from datadog_api_client.v1.model.widget_display_type import WidgetDisplayType
from datadog_api_client.v1.model.widget_line_type import WidgetLineType
from datadog_api_client.v1.model.widget_line_width import WidgetLineWidth
from datadog_api_client.v1.model.widget_live_span import WidgetLiveSpan

body = NotebookCreateRequest(
    data=NotebookCreateData(
        attributes=NotebookCreateDataAttributes(
            cells=[
                NotebookCellCreateRequest(
                    attributes=NotebookMarkdownCellAttributes(
                        definition=NotebookMarkdownCellDefinition(
                            text="## Some test markdown\n\n```\nvar x, y;\nx = 5;\ny = 6;\n```",
                            type=NotebookMarkdownCellDefinitionType.MARKDOWN,
                        ),
                    ),
                    type=NotebookCellResourceType.NOTEBOOK_CELLS,
                ),
                NotebookCellCreateRequest(
                    attributes=NotebookTimeseriesCellAttributes(
                        definition=TimeseriesWidgetDefinition(
                            requests=[
                                TimeseriesWidgetRequest(
                                    display_type=WidgetDisplayType.LINE,
                                    q="avg:system.load.1{*}",
                                    style=TimeseriesRequestStyle(
                                        line_type=WidgetLineType.SOLID,
                                        line_width=WidgetLineWidth.NORMAL,
                                        palette="dog_classic",
                                    ),
                                ),
                            ],
                            show_legend=True,
                            type=TimeseriesWidgetDefinitionType.TIMESERIES,
                            yaxis=WidgetAxis(
                                scale="linear",
                            ),
                        ),
                        graph_size=NotebookGraphSize.MEDIUM,
                        split_by=NotebookSplitBy(
                            keys=[],
                            tags=[],
                        ),
                        time=None,
                    ),
                    type=NotebookCellResourceType.NOTEBOOK_CELLS,
                ),
            ],
            name="Example-Notebook",
            status=NotebookStatus.PUBLISHED,
            time=NotebookRelativeTime(
                live_span=WidgetLiveSpan.PAST_ONE_HOUR,
            ),
        ),
        type=NotebookResourceType.NOTEBOOKS,
    ),
)

configuration = Configuration()
with ApiClient(configuration) as api_client:
    api_instance = NotebooksApi(api_client)
    response = api_instance.create_notebook(body=body)

    print(response)
````

#### Instructions

First [install the library and its dependencies](https://docs.datadoghq.com/api/latest.md?code-lang=python) and then save the example to `example.py` and run following commands:
    DD_SITE="datadoghq.com" DD_API_KEY="<API-KEY>" DD_APP_KEY="<APP-KEY>" python3 "example.py"
##### 

````ruby
# Create a notebook returns "OK" response

require "datadog_api_client"
api_instance = DatadogAPIClient::V1::NotebooksAPI.new

body = DatadogAPIClient::V1::NotebookCreateRequest.new({
  data: DatadogAPIClient::V1::NotebookCreateData.new({
    attributes: DatadogAPIClient::V1::NotebookCreateDataAttributes.new({
      cells: [
        DatadogAPIClient::V1::NotebookCellCreateRequest.new({
          attributes: DatadogAPIClient::V1::NotebookMarkdownCellAttributes.new({
            definition: DatadogAPIClient::V1::NotebookMarkdownCellDefinition.new({
              text: '## Some test markdown\n\n```\nvar x, y;\nx = 5;\ny = 6;\n```',
              type: DatadogAPIClient::V1::NotebookMarkdownCellDefinitionType::MARKDOWN,
            }),
          }),
          type: DatadogAPIClient::V1::NotebookCellResourceType::NOTEBOOK_CELLS,
        }),
        DatadogAPIClient::V1::NotebookCellCreateRequest.new({
          attributes: DatadogAPIClient::V1::NotebookTimeseriesCellAttributes.new({
            definition: DatadogAPIClient::V1::TimeseriesWidgetDefinition.new({
              requests: [
                DatadogAPIClient::V1::TimeseriesWidgetRequest.new({
                  display_type: DatadogAPIClient::V1::WidgetDisplayType::LINE,
                  q: "avg:system.load.1{*}",
                  style: DatadogAPIClient::V1::TimeseriesRequestStyle.new({
                    line_type: DatadogAPIClient::V1::WidgetLineType::SOLID,
                    line_width: DatadogAPIClient::V1::WidgetLineWidth::NORMAL,
                    palette: "dog_classic",
                  }),
                }),
              ],
              show_legend: true,
              type: DatadogAPIClient::V1::TimeseriesWidgetDefinitionType::TIMESERIES,
              yaxis: DatadogAPIClient::V1::WidgetAxis.new({
                scale: "linear",
              }),
            }),
            graph_size: DatadogAPIClient::V1::NotebookGraphSize::MEDIUM,
            split_by: DatadogAPIClient::V1::NotebookSplitBy.new({
              keys: [],
              tags: [],
            }),
            time: nil,
          }),
          type: DatadogAPIClient::V1::NotebookCellResourceType::NOTEBOOK_CELLS,
        }),
      ],
      name: "Example-Notebook",
      status: DatadogAPIClient::V1::NotebookStatus::PUBLISHED,
      time: DatadogAPIClient::V1::NotebookRelativeTime.new({
        live_span: DatadogAPIClient::V1::WidgetLiveSpan::PAST_ONE_HOUR,
      }),
    }),
    type: DatadogAPIClient::V1::NotebookResourceType::NOTEBOOKS,
  }),
})
p api_instance.create_notebook(body)
````

#### Instructions

First [install the library and its dependencies](https://docs.datadoghq.com/api/latest.md?code-lang=ruby) and then save the example to `example.rb` and run following commands:
    DD_SITE="datadoghq.com" DD_API_KEY="<API-KEY>" DD_APP_KEY="<APP-KEY>" rb "example.rb"
##### 

````rust
// Create a notebook returns "OK" response
use datadog_api_client::datadog;
use datadog_api_client::datadogV1::api_notebooks::NotebooksAPI;
use datadog_api_client::datadogV1::model::NotebookCellCreateRequest;
use datadog_api_client::datadogV1::model::NotebookCellCreateRequestAttributes;
use datadog_api_client::datadogV1::model::NotebookCellResourceType;
use datadog_api_client::datadogV1::model::NotebookCreateData;
use datadog_api_client::datadogV1::model::NotebookCreateDataAttributes;
use datadog_api_client::datadogV1::model::NotebookCreateRequest;
use datadog_api_client::datadogV1::model::NotebookGlobalTime;
use datadog_api_client::datadogV1::model::NotebookGraphSize;
use datadog_api_client::datadogV1::model::NotebookMarkdownCellAttributes;
use datadog_api_client::datadogV1::model::NotebookMarkdownCellDefinition;
use datadog_api_client::datadogV1::model::NotebookMarkdownCellDefinitionType;
use datadog_api_client::datadogV1::model::NotebookRelativeTime;
use datadog_api_client::datadogV1::model::NotebookResourceType;
use datadog_api_client::datadogV1::model::NotebookSplitBy;
use datadog_api_client::datadogV1::model::NotebookStatus;
use datadog_api_client::datadogV1::model::NotebookTimeseriesCellAttributes;
use datadog_api_client::datadogV1::model::TimeseriesRequestStyle;
use datadog_api_client::datadogV1::model::TimeseriesWidgetDefinition;
use datadog_api_client::datadogV1::model::TimeseriesWidgetDefinitionType;
use datadog_api_client::datadogV1::model::TimeseriesWidgetRequest;
use datadog_api_client::datadogV1::model::WidgetAxis;
use datadog_api_client::datadogV1::model::WidgetDisplayType;
use datadog_api_client::datadogV1::model::WidgetLineType;
use datadog_api_client::datadogV1::model::WidgetLineWidth;
use datadog_api_client::datadogV1::model::WidgetLiveSpan;

#[tokio::main]
async fn main() {
    let body = NotebookCreateRequest::new(NotebookCreateData::new(
        NotebookCreateDataAttributes::new(
            vec![
                NotebookCellCreateRequest::new(
                    NotebookCellCreateRequestAttributes::NotebookMarkdownCellAttributes(Box::new(
                        NotebookMarkdownCellAttributes::new(NotebookMarkdownCellDefinition::new(
                            r#"## Some test markdown

```
var x, y;
x = 5;
y = 6;
```"#
                                .to_string(),
                            NotebookMarkdownCellDefinitionType::MARKDOWN,
                        )),
                    )),
                    NotebookCellResourceType::NOTEBOOK_CELLS,
                ),
                NotebookCellCreateRequest::new(
                    NotebookCellCreateRequestAttributes::NotebookTimeseriesCellAttributes(
                        Box::new(
                            NotebookTimeseriesCellAttributes::new(
                                TimeseriesWidgetDefinition::new(
                                    vec![TimeseriesWidgetRequest::new()
                                        .display_type(WidgetDisplayType::LINE)
                                        .q("avg:system.load.1{*}".to_string())
                                        .style(
                                            TimeseriesRequestStyle::new()
                                                .line_type(WidgetLineType::SOLID)
                                                .line_width(WidgetLineWidth::NORMAL)
                                                .palette("dog_classic".to_string()),
                                        )],
                                    TimeseriesWidgetDefinitionType::TIMESERIES,
                                )
                                .show_legend(true)
                                .yaxis(WidgetAxis::new().scale("linear".to_string())),
                            )
                            .graph_size(NotebookGraphSize::MEDIUM)
                            .split_by(NotebookSplitBy::new(vec![], vec![]))
                            .time(None),
                        ),
                    ),
                    NotebookCellResourceType::NOTEBOOK_CELLS,
                ),
            ],
            "Example-Notebook".to_string(),
            NotebookGlobalTime::NotebookRelativeTime(Box::new(NotebookRelativeTime::new(
                WidgetLiveSpan::PAST_ONE_HOUR,
            ))),
        )
        .status(NotebookStatus::PUBLISHED),
        NotebookResourceType::NOTEBOOKS,
    ));
    let configuration = datadog::Configuration::new();
    let api = NotebooksAPI::with_config(configuration);
    let resp = api.create_notebook(body).await;
    if let Ok(value) = resp {
        println!("{:#?}", value);
    } else {
        println!("{:#?}", resp.unwrap_err());
    }
}
````

#### Instructions

First [install the library and its dependencies](https://docs.datadoghq.com/api/latest.md?code-lang=rust) and then save the example to `src/main.rs` and run following commands:
    DD_SITE="datadoghq.com" DD_API_KEY="<API-KEY>" DD_APP_KEY="<APP-KEY>" cargo run
##### 

````typescript
/**
 * Create a notebook returns "OK" response
 */

import { client, v1 } from "@datadog/datadog-api-client";

const configuration = client.createConfiguration();
const apiInstance = new v1.NotebooksApi(configuration);

const params: v1.NotebooksApiCreateNotebookRequest = {
  body: {
    data: {
      attributes: {
        cells: [
          {
            attributes: {
              definition: {
                text:
                  `## Some test markdown

` +
                  "```" +
                  `
var x, y;
x = 5;
y = 6;
` +
                  "```",
                type: "markdown",
              },
            },
            type: "notebook_cells",
          },
          {
            attributes: {
              definition: {
                requests: [
                  {
                    displayType: "line",
                    q: "avg:system.load.1{*}",
                    style: {
                      lineType: "solid",
                      lineWidth: "normal",
                      palette: "dog_classic",
                    },
                  },
                ],
                showLegend: true,
                type: "timeseries",
                yaxis: {
                  scale: "linear",
                },
              },
              graphSize: "m",
              splitBy: {
                keys: [],
                tags: [],
              },
              time: undefined,
            },
            type: "notebook_cells",
          },
        ],
        name: "Example-Notebook",
        status: "published",
        time: {
          liveSpan: "1h",
        },
      },
      type: "notebooks",
    },
  },
};

apiInstance
  .createNotebook(params)
  .then((data: v1.NotebookResponse) => {
    console.log(
      "API called successfully. Returned data: " + JSON.stringify(data)
    );
  })
  .catch((error: any) => console.error(error));
````

#### Instructions

First [install the library and its dependencies](https://docs.datadoghq.com/api/latest.md?code-lang=typescript) and then save the example to `example.ts` and run following commands:
    DD_SITE="datadoghq.com" DD_API_KEY="<API-KEY>" DD_APP_KEY="<APP-KEY>" tsc "example.ts"
{% /tab %}
