Skip to content

Commit aa8df54

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Allow Table Widget requests to specify text replace formatting in dashboards (#279)
Co-authored-by: ci.datadog-api-spec <[email protected]> Co-authored-by: api-clients-generation-pipeline[bot] <54105614+api-clients-generation-pipeline[bot]@users.noreply.github.com>
1 parent db92371 commit aa8df54

18 files changed

+1470
-4
lines changed

.apigentools-info

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"spec_versions": {
55
"v1": {
66
"apigentools_version": "1.6.6",
7-
"regenerated": "2024-09-13 20:35:27.418968",
8-
"spec_repo_commit": "6093038f"
7+
"regenerated": "2024-09-16 14:02:52.161932",
8+
"spec_repo_commit": "966987f5"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2024-09-13 20:35:27.437228",
13-
"spec_repo_commit": "6093038f"
12+
"regenerated": "2024-09-16 14:02:52.179359",
13+
"spec_repo_commit": "966987f5"
1414
}
1515
}
1616
}

.generator/schemas/v1/openapi.yaml

Lines changed: 175 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16752,6 +16752,181 @@ components:
1675216752
$ref: '#/components/schemas/LogQueryDefinition'
1675316753
sort:
1675416754
$ref: '#/components/schemas/WidgetSortBy'
16755+
text_formats:
16756+
description: List of text formats for columns produced by tags.
16757+
items:
16758+
$ref: '#/components/schemas/TableWidgetTextFormat'
16759+
type: array
16760+
type: object
16761+
TableWidgetTextFormat:
16762+
description: Text format rules for a tag-based column within a table widget.
16763+
example:
16764+
- match:
16765+
type: is
16766+
value: fruit
16767+
replace:
16768+
type: all
16769+
with: vegetable
16770+
- match:
16771+
type: is
16772+
value: cake
16773+
palette: white_on_green
16774+
items:
16775+
$ref: '#/components/schemas/TableWidgetTextFormatRule'
16776+
minItems: 1
16777+
type: array
16778+
TableWidgetTextFormatMatch:
16779+
description: Match rule for the table widget text format.
16780+
example:
16781+
type: is
16782+
value: fruit
16783+
properties:
16784+
type:
16785+
$ref: '#/components/schemas/TableWidgetTextFormatMatchType'
16786+
value:
16787+
description: Table Widget Match String.
16788+
example: Match Value
16789+
type: string
16790+
required:
16791+
- type
16792+
- value
16793+
type: object
16794+
TableWidgetTextFormatMatchType:
16795+
description: Match or compare option.
16796+
enum:
16797+
- is
16798+
- is_not
16799+
- contains
16800+
- does_not_contain
16801+
- starts_with
16802+
- ends_with
16803+
example: is
16804+
type: string
16805+
x-enum-varnames:
16806+
- IS
16807+
- IS_NOT
16808+
- CONTAINS
16809+
- DOES_NOT_CONTAIN
16810+
- STARTS_WITH
16811+
- ENDS_WITH
16812+
TableWidgetTextFormatPalette:
16813+
default: white_on_green
16814+
description: Color-on-color palette to highlight replaced text.
16815+
enum:
16816+
- white_on_red
16817+
- white_on_yellow
16818+
- white_on_green
16819+
- black_on_light_red
16820+
- black_on_light_yellow
16821+
- black_on_light_green
16822+
- red_on_white
16823+
- yellow_on_white
16824+
- green_on_white
16825+
- custom_bg
16826+
- custom_text
16827+
type: string
16828+
x-enum-varnames:
16829+
- WHITE_ON_RED
16830+
- WHITE_ON_YELLOW
16831+
- WHITE_ON_GREEN
16832+
- BLACK_ON_LIGHT_RED
16833+
- BLACK_ON_LIGHT_YELLOW
16834+
- BLACK_ON_LIGHT_GREEN
16835+
- RED_ON_WHITE
16836+
- YELLOW_ON_WHITE
16837+
- GREEN_ON_WHITE
16838+
- CUSTOM_BG
16839+
- CUSTOM_TEXT
16840+
TableWidgetTextFormatReplace:
16841+
description: Replace rule for the table widget text format.
16842+
example:
16843+
type: all
16844+
with: vegetable
16845+
oneOf:
16846+
- $ref: '#/components/schemas/TableWidgetTextFormatReplaceAll'
16847+
- $ref: '#/components/schemas/TableWidgetTextFormatReplaceSubstring'
16848+
TableWidgetTextFormatReplaceAll:
16849+
description: Match All definition.
16850+
example:
16851+
type: all
16852+
with: vegetable
16853+
properties:
16854+
type:
16855+
$ref: '#/components/schemas/TableWidgetTextFormatReplaceAllType'
16856+
with:
16857+
description: Replace All type.
16858+
example: all
16859+
type: string
16860+
required:
16861+
- type
16862+
- with
16863+
type: object
16864+
TableWidgetTextFormatReplaceAllType:
16865+
description: Table widget text format replace all type.
16866+
enum:
16867+
- all
16868+
example: all
16869+
type: string
16870+
x-enum-varnames:
16871+
- ALL
16872+
TableWidgetTextFormatReplaceSubstring:
16873+
description: Match Sub-string definition.
16874+
example:
16875+
substring: fruit
16876+
type: substring
16877+
with: vegetable
16878+
properties:
16879+
substring:
16880+
description: Text that will be replaced.
16881+
example: string to replace
16882+
type: string
16883+
type:
16884+
$ref: '#/components/schemas/TableWidgetTextFormatReplaceSubstringType'
16885+
with:
16886+
description: Text that will replace original sub-string.
16887+
example: replacement
16888+
type: string
16889+
required:
16890+
- type
16891+
- with
16892+
- substring
16893+
type: object
16894+
TableWidgetTextFormatReplaceSubstringType:
16895+
description: Table widget text format replace sub-string type.
16896+
enum:
16897+
- substring
16898+
example: substring
16899+
type: string
16900+
x-enum-varnames:
16901+
- SUBSTRING
16902+
TableWidgetTextFormatRule:
16903+
description: Text format rules.
16904+
example:
16905+
match:
16906+
type: is
16907+
value: apple
16908+
replace:
16909+
type: all
16910+
with: vegetable
16911+
properties:
16912+
custom_bg_color:
16913+
description: Hex representation of the custom background color. Used with
16914+
custom background palette option.
16915+
example: '#632ca6'
16916+
type: string
16917+
custom_fg_color:
16918+
description: Hex representation of the custom text color. Used with custom
16919+
text palette option.
16920+
example: '#632ca6'
16921+
type: string
16922+
match:
16923+
$ref: '#/components/schemas/TableWidgetTextFormatMatch'
16924+
palette:
16925+
$ref: '#/components/schemas/TableWidgetTextFormatPalette'
16926+
replace:
16927+
$ref: '#/components/schemas/TableWidgetTextFormatReplace'
16928+
required:
16929+
- match
1675516930
type: object
1675616931
TagToHosts:
1675716932
description: In this object, the key is the tag, the value is a list of host

0 commit comments

Comments
 (0)