Skip to content

Commit 02c2672

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 7f7d269e of spec repo
1 parent 9221073 commit 02c2672

25 files changed

+233
-69
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-08-29 20:02:03.124770",
8-
"spec_repo_commit": "518ca9df"
7+
"regenerated": "2024-09-02 13:49:36.900856",
8+
"spec_repo_commit": "7f7d269e"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2024-08-29 20:02:03.141872",
13-
"spec_repo_commit": "518ca9df"
12+
"regenerated": "2024-09-02 13:49:36.917902",
13+
"spec_repo_commit": "7f7d269e"
1414
}
1515
}
1616
}

.generator/schemas/v1/openapi.yaml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13872,6 +13872,7 @@ components:
1387213872
- $ref: '#/components/schemas/SyntheticsAssertionJSONPathTarget'
1387313873
- $ref: '#/components/schemas/SyntheticsAssertionJSONSchemaTarget'
1387413874
- $ref: '#/components/schemas/SyntheticsAssertionXPathTarget'
13875+
- $ref: '#/components/schemas/SyntheticsAssertionJavascript'
1387513876
SyntheticsAssertionBodyHashOperator:
1387613877
description: Assertion operator to apply.
1387713878
enum:
@@ -13988,6 +13989,27 @@ components:
1398813989
metaSchema:
1398913990
$ref: '#/components/schemas/SyntheticsAssertionJSONSchemaMetaSchema'
1399013991
type: object
13992+
SyntheticsAssertionJavascript:
13993+
description: A JavaScript assertion.
13994+
properties:
13995+
code:
13996+
description: The JavaScript code that performs the assertions.
13997+
example: dd.expect(dd.response.statusCode).to.equal(200);
13998+
type: string
13999+
type:
14000+
$ref: '#/components/schemas/SyntheticsAssertionJavascriptType'
14001+
required:
14002+
- type
14003+
- code
14004+
type: object
14005+
SyntheticsAssertionJavascriptType:
14006+
description: Type of the assertion.
14007+
enum:
14008+
- javascript
14009+
example: javascript
14010+
type: string
14011+
x-enum-varnames:
14012+
- JAVASCRIPT
1399114013
SyntheticsAssertionOperator:
1399214014
description: Assertion operator to apply.
1399314015
enum:

docs/datadog_api_client.v1.model.rst

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3910,6 +3910,20 @@ datadog\_api\_client.v1.model.synthetics\_assertion\_body\_hash\_type module
39103910
:members:
39113911
:show-inheritance:
39123912

3913+
datadog\_api\_client.v1.model.synthetics\_assertion\_javascript module
3914+
----------------------------------------------------------------------
3915+
3916+
.. automodule:: datadog_api_client.v1.model.synthetics_assertion_javascript
3917+
:members:
3918+
:show-inheritance:
3919+
3920+
datadog\_api\_client.v1.model.synthetics\_assertion\_javascript\_type module
3921+
----------------------------------------------------------------------------
3922+
3923+
.. automodule:: datadog_api_client.v1.model.synthetics_assertion_javascript_type
3924+
:members:
3925+
:show-inheritance:
3926+
39133927
datadog\_api\_client.v1.model.synthetics\_assertion\_json\_path\_operator module
39143928
--------------------------------------------------------------------------------
39153929

examples/v1/synthetics/CreateSyntheticsAPITest_1487281163.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010
from datadog_api_client.v1.model.synthetics_assertion_body_hash_operator import SyntheticsAssertionBodyHashOperator
1111
from datadog_api_client.v1.model.synthetics_assertion_body_hash_target import SyntheticsAssertionBodyHashTarget
1212
from datadog_api_client.v1.model.synthetics_assertion_body_hash_type import SyntheticsAssertionBodyHashType
13+
from datadog_api_client.v1.model.synthetics_assertion_javascript import SyntheticsAssertionJavascript
14+
from datadog_api_client.v1.model.synthetics_assertion_javascript_type import SyntheticsAssertionJavascriptType
1315
from datadog_api_client.v1.model.synthetics_assertion_json_path_operator import SyntheticsAssertionJSONPathOperator
1416
from datadog_api_client.v1.model.synthetics_assertion_json_path_target import SyntheticsAssertionJSONPathTarget
1517
from datadog_api_client.v1.model.synthetics_assertion_json_path_target_target import (
@@ -103,6 +105,10 @@
103105
target="a",
104106
type=SyntheticsAssertionBodyHashType.BODY_HASH,
105107
),
108+
SyntheticsAssertionJavascript(
109+
code="const hello = 'world';",
110+
type=SyntheticsAssertionJavascriptType.JAVASCRIPT,
111+
),
106112
],
107113
config_variables=[
108114
SyntheticsConfigVariable(

examples/v1/synthetics/CreateSyntheticsAPITest_1987645492.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010
from datadog_api_client.v1.model.synthetics_assertion_body_hash_operator import SyntheticsAssertionBodyHashOperator
1111
from datadog_api_client.v1.model.synthetics_assertion_body_hash_target import SyntheticsAssertionBodyHashTarget
1212
from datadog_api_client.v1.model.synthetics_assertion_body_hash_type import SyntheticsAssertionBodyHashType
13+
from datadog_api_client.v1.model.synthetics_assertion_javascript import SyntheticsAssertionJavascript
14+
from datadog_api_client.v1.model.synthetics_assertion_javascript_type import SyntheticsAssertionJavascriptType
1315
from datadog_api_client.v1.model.synthetics_assertion_json_path_operator import SyntheticsAssertionJSONPathOperator
1416
from datadog_api_client.v1.model.synthetics_assertion_json_path_target import SyntheticsAssertionJSONPathTarget
1517
from datadog_api_client.v1.model.synthetics_assertion_json_path_target_target import (
@@ -103,6 +105,10 @@
103105
target="a",
104106
type=SyntheticsAssertionBodyHashType.BODY_HASH,
105107
),
108+
SyntheticsAssertionJavascript(
109+
code="const hello = 'world';",
110+
type=SyntheticsAssertionJavascriptType.JAVASCRIPT,
111+
),
106112
],
107113
config_variables=[
108114
SyntheticsConfigVariable(

src/datadog_api_client/v1/model/synthetics_api_test_config.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
from datadog_api_client.v1.model.synthetics_assertion_json_path_target import SyntheticsAssertionJSONPathTarget
2424
from datadog_api_client.v1.model.synthetics_assertion_json_schema_target import SyntheticsAssertionJSONSchemaTarget
2525
from datadog_api_client.v1.model.synthetics_assertion_x_path_target import SyntheticsAssertionXPathTarget
26+
from datadog_api_client.v1.model.synthetics_assertion_javascript import SyntheticsAssertionJavascript
2627
from datadog_api_client.v1.model.synthetics_api_test_step import SyntheticsAPITestStep
2728
from datadog_api_client.v1.model.synthetics_api_wait_step import SyntheticsAPIWaitStep
2829

@@ -62,6 +63,7 @@ def __init__(
6263
SyntheticsAssertionJSONPathTarget,
6364
SyntheticsAssertionJSONSchemaTarget,
6465
SyntheticsAssertionXPathTarget,
66+
SyntheticsAssertionJavascript,
6567
]
6668
],
6769
UnsetType,

src/datadog_api_client/v1/model/synthetics_assertion.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,9 @@ def __init__(self, **kwargs):
3030
3131
:param type: Type of the assertion.
3232
:type type: SyntheticsAssertionType
33+
34+
:param code: The JavaScript code that performs the assertions.
35+
:type code: str
3336
"""
3437
super().__init__(kwargs)
3538

@@ -49,6 +52,7 @@ def _composed_schemas(_):
4952
SyntheticsAssertionJSONSchemaTarget,
5053
)
5154
from datadog_api_client.v1.model.synthetics_assertion_x_path_target import SyntheticsAssertionXPathTarget
55+
from datadog_api_client.v1.model.synthetics_assertion_javascript import SyntheticsAssertionJavascript
5256

5357
return {
5458
"oneOf": [
@@ -57,5 +61,6 @@ def _composed_schemas(_):
5761
SyntheticsAssertionJSONPathTarget,
5862
SyntheticsAssertionJSONSchemaTarget,
5963
SyntheticsAssertionXPathTarget,
64+
SyntheticsAssertionJavascript,
6065
],
6166
}
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
2+
# This product includes software developed at Datadog (https://www.datadoghq.com/).
3+
# Copyright 2019-Present Datadog, Inc.
4+
from __future__ import annotations
5+
6+
from typing import TYPE_CHECKING
7+
8+
from datadog_api_client.model_utils import (
9+
ModelNormal,
10+
cached_property,
11+
)
12+
13+
14+
if TYPE_CHECKING:
15+
from datadog_api_client.v1.model.synthetics_assertion_javascript_type import SyntheticsAssertionJavascriptType
16+
17+
18+
class SyntheticsAssertionJavascript(ModelNormal):
19+
@cached_property
20+
def openapi_types(_):
21+
from datadog_api_client.v1.model.synthetics_assertion_javascript_type import SyntheticsAssertionJavascriptType
22+
23+
return {
24+
"code": (str,),
25+
"type": (SyntheticsAssertionJavascriptType,),
26+
}
27+
28+
attribute_map = {
29+
"code": "code",
30+
"type": "type",
31+
}
32+
33+
def __init__(self_, code: str, type: SyntheticsAssertionJavascriptType, **kwargs):
34+
"""
35+
A JavaScript assertion.
36+
37+
:param code: The JavaScript code that performs the assertions.
38+
:type code: str
39+
40+
:param type: Type of the assertion.
41+
:type type: SyntheticsAssertionJavascriptType
42+
"""
43+
super().__init__(kwargs)
44+
45+
self_.code = code
46+
self_.type = type
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
2+
# This product includes software developed at Datadog (https://www.datadoghq.com/).
3+
# Copyright 2019-Present Datadog, Inc.
4+
from __future__ import annotations
5+
6+
7+
from datadog_api_client.model_utils import (
8+
ModelSimple,
9+
cached_property,
10+
)
11+
12+
from typing import ClassVar
13+
14+
15+
class SyntheticsAssertionJavascriptType(ModelSimple):
16+
"""
17+
Type of the assertion.
18+
19+
:param value: If omitted defaults to "javascript". Must be one of ["javascript"].
20+
:type value: str
21+
"""
22+
23+
allowed_values = {
24+
"javascript",
25+
}
26+
JAVASCRIPT: ClassVar["SyntheticsAssertionJavascriptType"]
27+
28+
@cached_property
29+
def openapi_types(_):
30+
return {
31+
"value": (str,),
32+
}
33+
34+
35+
SyntheticsAssertionJavascriptType.JAVASCRIPT = SyntheticsAssertionJavascriptType("javascript")

src/datadog_api_client/v1/model/synthetics_test_config.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
from datadog_api_client.v1.model.synthetics_assertion_json_path_target import SyntheticsAssertionJSONPathTarget
2424
from datadog_api_client.v1.model.synthetics_assertion_json_schema_target import SyntheticsAssertionJSONSchemaTarget
2525
from datadog_api_client.v1.model.synthetics_assertion_x_path_target import SyntheticsAssertionXPathTarget
26+
from datadog_api_client.v1.model.synthetics_assertion_javascript import SyntheticsAssertionJavascript
2627

2728

2829
class SyntheticsTestConfig(ModelNormal):
@@ -58,6 +59,7 @@ def __init__(
5859
SyntheticsAssertionJSONPathTarget,
5960
SyntheticsAssertionJSONSchemaTarget,
6061
SyntheticsAssertionXPathTarget,
62+
SyntheticsAssertionJavascript,
6163
]
6264
],
6365
UnsetType,

src/datadog_api_client/v1/models/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -641,6 +641,8 @@
641641
from datadog_api_client.v1.model.synthetics_assertion_json_schema_target_target import (
642642
SyntheticsAssertionJSONSchemaTargetTarget,
643643
)
644+
from datadog_api_client.v1.model.synthetics_assertion_javascript import SyntheticsAssertionJavascript
645+
from datadog_api_client.v1.model.synthetics_assertion_javascript_type import SyntheticsAssertionJavascriptType
644646
from datadog_api_client.v1.model.synthetics_assertion_operator import SyntheticsAssertionOperator
645647
from datadog_api_client.v1.model.synthetics_assertion_target import SyntheticsAssertionTarget
646648
from datadog_api_client.v1.model.synthetics_assertion_timings_scope import SyntheticsAssertionTimingsScope
@@ -1548,6 +1550,8 @@
15481550
"SyntheticsAssertionJSONSchemaOperator",
15491551
"SyntheticsAssertionJSONSchemaTarget",
15501552
"SyntheticsAssertionJSONSchemaTargetTarget",
1553+
"SyntheticsAssertionJavascript",
1554+
"SyntheticsAssertionJavascriptType",
15511555
"SyntheticsAssertionOperator",
15521556
"SyntheticsAssertionTarget",
15531557
"SyntheticsAssertionTimingsScope",
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2024-06-14T14:40:25.126Z
1+
2024-08-05T15:40:27.317Z

0 commit comments

Comments
 (0)