Skip to content

Commit db7500f

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Regenerate client from commit f614243 of spec repo (#308)
Co-authored-by: ci.datadog-api-spec <[email protected]>
1 parent 2bafb38 commit db7500f

File tree

9 files changed

+246
-4
lines changed

9 files changed

+246
-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.4.1.dev8",
7-
"regenerated": "2021-03-05 09:33:11.594025",
8-
"spec_repo_commit": "aad6dbb"
7+
"regenerated": "2021-03-05 15:51:21.070609",
8+
"spec_repo_commit": "f614243"
99
},
1010
"v2": {
1111
"apigentools_version": "1.4.1.dev8",
12-
"regenerated": "2021-03-05 09:33:46.163813",
13-
"spec_repo_commit": "aad6dbb"
12+
"regenerated": "2021-03-05 15:52:06.307614",
13+
"spec_repo_commit": "f614243"
1414
}
1515
}
1616
}

docs/v1/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -598,6 +598,7 @@ Class | Method | HTTP request | Description
598598
- [SyntheticsCheckType](SyntheticsCheckType.md)
599599
- [SyntheticsConfigVariable](SyntheticsConfigVariable.md)
600600
- [SyntheticsConfigVariableType](SyntheticsConfigVariableType.md)
601+
- [SyntheticsCoreWebVitals](SyntheticsCoreWebVitals.md)
601602
- [SyntheticsDeleteTestsPayload](SyntheticsDeleteTestsPayload.md)
602603
- [SyntheticsDeleteTestsResponse](SyntheticsDeleteTestsResponse.md)
603604
- [SyntheticsDeletedTest](SyntheticsDeletedTest.md)

docs/v1/SyntheticsCoreWebVitals.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# SyntheticsCoreWebVitals
2+
3+
Core Web Vitals attached to a browser test step.
4+
## Properties
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**cls** | **int** | Cumulative Layout Shift. | [optional]
8+
**lcp** | **int** | Largest Contentful Paint in milliseconds. | [optional]
9+
**url** | **str** | URL attached to the metrics. | [optional]
10+
11+
[[Back to Model list]](README.md#documentation-for-models) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to README]](README.md)
12+
13+

docs/v1/SyntheticsStepDetail.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ Name | Type | Description | Notes
1919
**type** | [**SyntheticsStepType**](SyntheticsStepType.md) | | [optional]
2020
**url** | **str** | URL to perform the step against. | [optional]
2121
**value** | **{str: (bool, date, datetime, dict, float, int, list, str, none_type)}** | Value for the step. | [optional]
22+
**vitals_metrics** | [**[SyntheticsCoreWebVitals]**](SyntheticsCoreWebVitals.md) | Array of Core Web Vitals metrics for the step. | [optional]
2223
**warnings** | [**[SyntheticsStepDetailWarning]**](SyntheticsStepDetailWarning.md) | Warning collected that didn&#39;t failed the step. | [optional]
2324

2425
[[Back to Model list]](README.md#documentation-for-models) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to README]](README.md)
Lines changed: 171 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,171 @@
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+
5+
6+
import re # noqa: F401
7+
import sys # noqa: F401
8+
9+
import nulltype # noqa: F401
10+
11+
from datadog_api_client.v1.model_utils import ( # noqa: F401
12+
ApiTypeError,
13+
ModelComposed,
14+
ModelNormal,
15+
ModelSimple,
16+
cached_property,
17+
change_keys_js_to_python,
18+
convert_js_args_to_python_args,
19+
date,
20+
datetime,
21+
file_type,
22+
none_type,
23+
validate_get_composed_info,
24+
)
25+
26+
27+
class SyntheticsCoreWebVitals(ModelNormal):
28+
"""NOTE: This class is auto generated by OpenAPI Generator.
29+
Ref: https://openapi-generator.tech
30+
31+
Do not edit the class manually.
32+
33+
Attributes:
34+
allowed_values (dict): The key is the tuple path to the attribute
35+
and the for var_name this is (var_name,). The value is a dict
36+
with a capitalized key describing the allowed value and an allowed
37+
value. These dicts store the allowed enum values.
38+
attribute_map (dict): The key is attribute name
39+
and the value is json key in definition.
40+
discriminator_value_class_map (dict): A dict to go from the discriminator
41+
variable value to the discriminator class name.
42+
validations (dict): The key is the tuple path to the attribute
43+
and the for var_name this is (var_name,). The value is a dict
44+
that stores validations for max_length, min_length, max_items,
45+
min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum,
46+
inclusive_minimum, and regex.
47+
additional_properties_type (tuple): A tuple of classes accepted
48+
as additional properties values.
49+
"""
50+
51+
allowed_values = {}
52+
53+
validations = {}
54+
55+
additional_properties_type = None
56+
57+
_nullable = False
58+
59+
@cached_property
60+
def openapi_types():
61+
"""
62+
This must be a method because a model may have properties that are
63+
of type self, this must run after the class is loaded
64+
65+
Returns
66+
openapi_types (dict): The key is attribute name
67+
and the value is attribute type.
68+
"""
69+
return {
70+
"cls": (int,), # noqa: E501
71+
"lcp": (int,), # noqa: E501
72+
"url": (str,), # noqa: E501
73+
}
74+
75+
@cached_property
76+
def discriminator():
77+
return None
78+
79+
attribute_map = {
80+
"cls": "cls", # noqa: E501
81+
"lcp": "lcp", # noqa: E501
82+
"url": "url", # noqa: E501
83+
}
84+
85+
_composed_schemas = {}
86+
87+
required_properties = set(
88+
[
89+
"_data_store",
90+
"_check_type",
91+
"_spec_property_naming",
92+
"_path_to_item",
93+
"_configuration",
94+
"_visited_composed_classes",
95+
]
96+
)
97+
98+
@convert_js_args_to_python_args
99+
def __init__(self, *args, **kwargs): # noqa: E501
100+
"""SyntheticsCoreWebVitals - a model defined in OpenAPI
101+
102+
Keyword Args:
103+
_check_type (bool): if True, values for parameters in openapi_types
104+
will be type checked and a TypeError will be
105+
raised if the wrong type is input.
106+
Defaults to True
107+
_path_to_item (tuple/list): This is a list of keys or values to
108+
drill down to the model in received_data
109+
when deserializing a response
110+
_spec_property_naming (bool): True if the variable names in the input data
111+
are serialized names, as specified in the OpenAPI document.
112+
False if the variable names in the input data
113+
are pythonic names, e.g. snake case (default)
114+
_configuration (Configuration): the instance to use when
115+
deserializing a file_type parameter.
116+
If passed, type conversion is attempted
117+
If omitted no type conversion is done.
118+
_visited_composed_classes (tuple): This stores a tuple of
119+
classes that we have traveled through so that
120+
if we see that class again we will not use its
121+
discriminator again.
122+
When traveling through a discriminator, the
123+
composed schema that is
124+
is traveled through is added to this set.
125+
For example if Animal has a discriminator
126+
petType and we pass in "Dog", and the class Dog
127+
allOf includes Animal, we move through Animal
128+
once using the discriminator, and pick Dog.
129+
Then in Dog, we will make an instance of the
130+
Animal class but this time we won't travel
131+
through its discriminator because we passed in
132+
_visited_composed_classes = (Animal,)
133+
cls (int): Cumulative Layout Shift.. [optional] # noqa: E501
134+
lcp (int): Largest Contentful Paint in milliseconds.. [optional] # noqa: E501
135+
url (str): URL attached to the metrics.. [optional] # noqa: E501
136+
"""
137+
138+
_check_type = kwargs.pop("_check_type", True)
139+
_spec_property_naming = kwargs.pop("_spec_property_naming", False)
140+
_path_to_item = kwargs.pop("_path_to_item", ())
141+
_configuration = kwargs.pop("_configuration", None)
142+
_visited_composed_classes = kwargs.pop("_visited_composed_classes", ())
143+
144+
if args:
145+
raise ApiTypeError(
146+
"Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments."
147+
% (
148+
args,
149+
self.__class__.__name__,
150+
),
151+
path_to_item=_path_to_item,
152+
valid_classes=(self.__class__,),
153+
)
154+
155+
self._data_store = {}
156+
self._check_type = _check_type
157+
self._spec_property_naming = _spec_property_naming
158+
self._path_to_item = _path_to_item
159+
self._configuration = _configuration
160+
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
161+
162+
for var_name, var_value in kwargs.items():
163+
if (
164+
var_name not in self.attribute_map
165+
and self._configuration is not None
166+
and self._configuration.discard_unknown_keys
167+
and self.additional_properties_type is None
168+
):
169+
# discard variable.
170+
continue
171+
setattr(self, var_name, var_value)

src/datadog_api_client/v1/model/synthetics_step_detail.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,14 @@
2727
def lazy_import():
2828
from datadog_api_client.v1.model.synthetics_browser_error import SyntheticsBrowserError
2929
from datadog_api_client.v1.model.synthetics_check_type import SyntheticsCheckType
30+
from datadog_api_client.v1.model.synthetics_core_web_vitals import SyntheticsCoreWebVitals
3031
from datadog_api_client.v1.model.synthetics_playing_tab import SyntheticsPlayingTab
3132
from datadog_api_client.v1.model.synthetics_step_detail_warning import SyntheticsStepDetailWarning
3233
from datadog_api_client.v1.model.synthetics_step_type import SyntheticsStepType
3334

3435
globals()["SyntheticsBrowserError"] = SyntheticsBrowserError
3536
globals()["SyntheticsCheckType"] = SyntheticsCheckType
37+
globals()["SyntheticsCoreWebVitals"] = SyntheticsCoreWebVitals
3638
globals()["SyntheticsPlayingTab"] = SyntheticsPlayingTab
3739
globals()["SyntheticsStepDetailWarning"] = SyntheticsStepDetailWarning
3840
globals()["SyntheticsStepType"] = SyntheticsStepType
@@ -97,6 +99,7 @@ def openapi_types():
9799
"type": (SyntheticsStepType,), # noqa: E501
98100
"url": (str,), # noqa: E501
99101
"value": ({str: (bool, date, datetime, dict, float, int, list, str, none_type)},), # noqa: E501
102+
"vitals_metrics": ([SyntheticsCoreWebVitals],), # noqa: E501
100103
"warnings": ([SyntheticsStepDetailWarning],), # noqa: E501
101104
}
102105

@@ -120,6 +123,7 @@ def discriminator():
120123
"type": "type", # noqa: E501
121124
"url": "url", # noqa: E501
122125
"value": "value", # noqa: E501
126+
"vitals_metrics": "vitalsMetrics", # noqa: E501
123127
"warnings": "warnings", # noqa: E501
124128
}
125129

@@ -186,6 +190,7 @@ def __init__(self, *args, **kwargs): # noqa: E501
186190
type (SyntheticsStepType): [optional] # noqa: E501
187191
url (str): URL to perform the step against.. [optional] # noqa: E501
188192
value ({str: (bool, date, datetime, dict, float, int, list, str, none_type)}): Value for the step.. [optional] # noqa: E501
193+
vitals_metrics ([SyntheticsCoreWebVitals]): Array of Core Web Vitals metrics for the step.. [optional] # noqa: E501
189194
warnings ([SyntheticsStepDetailWarning]): Warning collected that didn't failed the step.. [optional] # noqa: E501
190195
"""
191196

src/datadog_api_client/v1/models/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -345,6 +345,7 @@
345345
from datadog_api_client.v1.model.synthetics_check_type import SyntheticsCheckType
346346
from datadog_api_client.v1.model.synthetics_config_variable import SyntheticsConfigVariable
347347
from datadog_api_client.v1.model.synthetics_config_variable_type import SyntheticsConfigVariableType
348+
from datadog_api_client.v1.model.synthetics_core_web_vitals import SyntheticsCoreWebVitals
348349
from datadog_api_client.v1.model.synthetics_delete_tests_payload import SyntheticsDeleteTestsPayload
349350
from datadog_api_client.v1.model.synthetics_delete_tests_response import SyntheticsDeleteTestsResponse
350351
from datadog_api_client.v1.model.synthetics_deleted_test import SyntheticsDeletedTest

src/datadog_api_client/v1/openapi.yaml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6975,6 +6975,21 @@ components:
69756975
type: string
69766976
x-enum-varnames:
69776977
- TEXT
6978+
SyntheticsCoreWebVitals:
6979+
description: Core Web Vitals attached to a browser test step.
6980+
properties:
6981+
cls:
6982+
description: Cumulative Layout Shift.
6983+
format: int64
6984+
type: integer
6985+
lcp:
6986+
description: Largest Contentful Paint in milliseconds.
6987+
format: int64
6988+
type: integer
6989+
url:
6990+
description: URL attached to the metrics.
6991+
type: string
6992+
type: object
69786993
SyntheticsDeleteTestsPayload:
69796994
description: 'A JSON list of the ID or IDs of the Synthetic tests that you want
69806995

@@ -7497,6 +7512,11 @@ components:
74977512
value:
74987513
description: Value for the step.
74997514
type: object
7515+
vitalsMetrics:
7516+
description: Array of Core Web Vitals metrics for the step.
7517+
items:
7518+
$ref: '#/components/schemas/SyntheticsCoreWebVitals'
7519+
type: array
75007520
warnings:
75017521
description: Warning collected that didn't failed the step.
75027522
items:
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
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+
5+
6+
import sys
7+
import unittest
8+
9+
import datadog_api_client.v1
10+
from datadog_api_client.v1.model.synthetics_core_web_vitals import SyntheticsCoreWebVitals
11+
12+
13+
class TestSyntheticsCoreWebVitals(unittest.TestCase):
14+
"""SyntheticsCoreWebVitals unit test stubs"""
15+
16+
def setUp(self):
17+
pass
18+
19+
def tearDown(self):
20+
pass
21+
22+
def testSyntheticsCoreWebVitals(self):
23+
"""Test SyntheticsCoreWebVitals"""
24+
# FIXME: construct object with mandatory attributes with example values
25+
# model = SyntheticsCoreWebVitals() # noqa: E501
26+
pass
27+
28+
29+
if __name__ == "__main__":
30+
unittest.main()

0 commit comments

Comments
 (0)