Skip to content

Commit

Permalink
Add tileDef sort attribute (#1969)
Browse files Browse the repository at this point in the history
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
Co-authored-by: api-clients-generation-pipeline[bot] <54105614+api-clients-generation-pipeline[bot]@users.noreply.github.com>
  • Loading branch information
api-clients-generation-pipeline[bot] and ci.datadog-api-spec authored May 23, 2024
1 parent d10ff66 commit baeb322
Show file tree
Hide file tree
Showing 32 changed files with 751 additions and 68 deletions.
8 changes: 4 additions & 4 deletions .apigentools-info
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
"spec_versions": {
"v1": {
"apigentools_version": "1.6.6",
"regenerated": "2024-05-23 11:28:45.445301",
"spec_repo_commit": "b829bfa2"
"regenerated": "2024-05-23 18:14:53.777857",
"spec_repo_commit": "95a954a4"
},
"v2": {
"apigentools_version": "1.6.6",
"regenerated": "2024-05-23 11:28:45.464180",
"spec_repo_commit": "b829bfa2"
"regenerated": "2024-05-23 18:14:53.794945",
"spec_repo_commit": "95a954a4"
}
}
}
75 changes: 75 additions & 0 deletions .generator/schemas/v1/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3043,6 +3043,14 @@ components:
type: string
x-enum-varnames:
- METRIC
FormulaType:
description: Set the sort type to formula.
enum:
- formula
example: formula
type: string
x-enum-varnames:
- FORMULA
FreeTextWidgetDefinition:
description: Free text is a widget that allows you to add headings to your screenboard.
Commonly used to state the overall purpose of the dashboard. Only available
Expand Down Expand Up @@ -3411,6 +3419,8 @@ components:
$ref: '#/components/schemas/LogQueryDefinition'
security_query:
$ref: '#/components/schemas/LogQueryDefinition'
sort:
$ref: '#/components/schemas/WidgetSortBy'
type: object
GraphSnapshot:
description: Object representing a graph snapshot.
Expand All @@ -3431,6 +3441,14 @@ components:
example: https://app.datadoghq.com/s/f12345678/aaa-bbb-ccc
type: string
type: object
GroupType:
description: Set the sort type to group.
enum:
- group
example: group
type: string
x-enum-varnames:
- GROUP
GroupWidgetDefinition:
description: The groups widget allows you to keep similar graphs together on
your timeboard. Each group has a custom header, can hold one to many graphs,
Expand Down Expand Up @@ -16392,6 +16410,8 @@ components:
$ref: '#/components/schemas/LogQueryDefinition'
security_query:
$ref: '#/components/schemas/LogQueryDefinition'
sort:
$ref: '#/components/schemas/WidgetSortBy'
type: object
TagToHosts:
description: In this object, the key is the tag, the value is a list of host
Expand Down Expand Up @@ -16728,6 +16748,8 @@ components:
$ref: '#/components/schemas/LogQueryDefinition'
security_query:
$ref: '#/components/schemas/LogQueryDefinition'
sort:
$ref: '#/components/schemas/WidgetSortBy'
style:
$ref: '#/components/schemas/WidgetRequestStyle'
type: object
Expand Down Expand Up @@ -20939,6 +20961,24 @@ components:
order:
$ref: '#/components/schemas/QuerySortOrder'
type: object
WidgetFormulaSort:
description: The formula to sort the widget by.
properties:
index:
description: The index of the formula to sort by.
example: 0
format: int64
minimum: 0
type: integer
order:
$ref: '#/components/schemas/WidgetSort'
type:
$ref: '#/components/schemas/FormulaType'
required:
- type
- index
- order
type: object
WidgetFormulaStyle:
description: Styling options for widget formulas.
properties:
Expand All @@ -20953,6 +20993,22 @@ components:
format: int64
type: integer
type: object
WidgetGroupSort:
description: The group to sort the widget by.
properties:
name:
description: The name of the group.
example: group_name
type: string
order:
$ref: '#/components/schemas/WidgetSort'
type:
$ref: '#/components/schemas/GroupType'
required:
- type
- name
- order
type: object
WidgetGrouping:
description: The kind of grouping to use.
enum:
Expand Down Expand Up @@ -21328,6 +21384,25 @@ components:
x-enum-varnames:
- ASCENDING
- DESCENDING
WidgetSortBy:
description: The controls for sorting the widget.
properties:
count:
description: The number of items to limit the widget to.
format: int64
minimum: 0
type: integer
order_by:
description: The array of items to sort the widget by in order.
items:
$ref: '#/components/schemas/WidgetSortOrderBy'
type: array
type: object
WidgetSortOrderBy:
description: The item to sort the widget by.
oneOf:
- $ref: '#/components/schemas/WidgetFormulaSort'
- $ref: '#/components/schemas/WidgetGroupSort'
WidgetStyle:
description: Widget style definition.
properties:
Expand Down
42 changes: 42 additions & 0 deletions docs/datadog_api_client.v1.model.rst
Original file line number Diff line number Diff line change
Expand Up @@ -953,6 +953,13 @@ formula\_and\_function\_slo\_query\_type
:members:
:show-inheritance:

formula\_type
-------------

.. automodule:: datadog_api_client.v1.model.formula_type
:members:
:show-inheritance:

free\_text\_widget\_definition
------------------------------

Expand Down Expand Up @@ -1072,6 +1079,13 @@ graph\_snapshot
:members:
:show-inheritance:

group\_type
-----------

.. automodule:: datadog_api_client.v1.model.group_type
:members:
:show-inheritance:

group\_widget\_definition
-------------------------

Expand Down Expand Up @@ -5783,13 +5797,27 @@ widget\_formula\_limit
:members:
:show-inheritance:

widget\_formula\_sort
---------------------

.. automodule:: datadog_api_client.v1.model.widget_formula_sort
:members:
:show-inheritance:

widget\_formula\_style
----------------------

.. automodule:: datadog_api_client.v1.model.widget_formula_style
:members:
:show-inheritance:

widget\_group\_sort
-------------------

.. automodule:: datadog_api_client.v1.model.widget_group_sort
:members:
:show-inheritance:

widget\_grouping
----------------

Expand Down Expand Up @@ -5930,6 +5958,20 @@ widget\_sort
:members:
:show-inheritance:

widget\_sort\_by
----------------

.. automodule:: datadog_api_client.v1.model.widget_sort_by
:members:
:show-inheritance:

widget\_sort\_order\_by
-----------------------

.. automodule:: datadog_api_client.v1.model.widget_sort_order_by
:members:
:show-inheritance:

widget\_style
-------------

Expand Down
20 changes: 14 additions & 6 deletions examples/v1/dashboards/CreateDashboard_1213075383.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
FormulaAndFunctionMetricQueryDefinition,
)
from datadog_api_client.v1.model.formula_and_function_response_format import FormulaAndFunctionResponseFormat
from datadog_api_client.v1.model.query_sort_order import QuerySortOrder
from datadog_api_client.v1.model.formula_type import FormulaType
from datadog_api_client.v1.model.toplist_widget_definition import ToplistWidgetDefinition
from datadog_api_client.v1.model.toplist_widget_definition_type import ToplistWidgetDefinitionType
from datadog_api_client.v1.model.toplist_widget_legend import ToplistWidgetLegend
Expand All @@ -23,8 +23,10 @@
from datadog_api_client.v1.model.toplist_widget_style import ToplistWidgetStyle
from datadog_api_client.v1.model.widget import Widget
from datadog_api_client.v1.model.widget_formula import WidgetFormula
from datadog_api_client.v1.model.widget_formula_limit import WidgetFormulaLimit
from datadog_api_client.v1.model.widget_formula_sort import WidgetFormulaSort
from datadog_api_client.v1.model.widget_layout import WidgetLayout
from datadog_api_client.v1.model.widget_sort import WidgetSort
from datadog_api_client.v1.model.widget_sort_by import WidgetSortBy
from datadog_api_client.v1.model.widget_text_align import WidgetTextAlign
from datadog_api_client.v1.model.widget_time import WidgetTime

Expand Down Expand Up @@ -65,12 +67,18 @@
formulas=[
WidgetFormula(
formula="query1",
limit=WidgetFormulaLimit(
count=10,
order=QuerySortOrder.DESC,
),
),
],
sort=WidgetSortBy(
count=10,
order_by=[
WidgetFormulaSort(
type=FormulaType.FORMULA,
index=0,
order=WidgetSort.DESCENDING,
),
],
),
response_format=FormulaAndFunctionResponseFormat.SCALAR,
),
],
Expand Down
20 changes: 14 additions & 6 deletions examples/v1/dashboards/CreateDashboard_2336428357.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,18 @@
FormulaAndFunctionMetricQueryDefinition,
)
from datadog_api_client.v1.model.formula_and_function_response_format import FormulaAndFunctionResponseFormat
from datadog_api_client.v1.model.query_sort_order import QuerySortOrder
from datadog_api_client.v1.model.formula_type import FormulaType
from datadog_api_client.v1.model.table_widget_cell_display_mode import TableWidgetCellDisplayMode
from datadog_api_client.v1.model.table_widget_definition import TableWidgetDefinition
from datadog_api_client.v1.model.table_widget_definition_type import TableWidgetDefinitionType
from datadog_api_client.v1.model.table_widget_has_search_bar import TableWidgetHasSearchBar
from datadog_api_client.v1.model.table_widget_request import TableWidgetRequest
from datadog_api_client.v1.model.widget import Widget
from datadog_api_client.v1.model.widget_formula import WidgetFormula
from datadog_api_client.v1.model.widget_formula_limit import WidgetFormulaLimit
from datadog_api_client.v1.model.widget_formula_sort import WidgetFormulaSort
from datadog_api_client.v1.model.widget_layout import WidgetLayout
from datadog_api_client.v1.model.widget_sort import WidgetSort
from datadog_api_client.v1.model.widget_sort_by import WidgetSortBy
from datadog_api_client.v1.model.widget_text_align import WidgetTextAlign
from datadog_api_client.v1.model.widget_time import WidgetTime

Expand Down Expand Up @@ -55,14 +57,20 @@
formulas=[
WidgetFormula(
formula="query1",
limit=WidgetFormulaLimit(
count=500,
order=QuerySortOrder.DESC,
),
conditional_formats=[],
cell_display_mode=TableWidgetCellDisplayMode.BAR,
),
],
sort=WidgetSortBy(
count=500,
order_by=[
WidgetFormulaSort(
type=FormulaType.FORMULA,
index=0,
order=WidgetSort.DESCENDING,
),
],
),
response_format=FormulaAndFunctionResponseFormat.SCALAR,
),
],
Expand Down
Loading

0 comments on commit baeb322

Please sign in to comment.