criteo-api-retailmedia-sdk 2025.1.0.250129__py3-none-any.whl → 2025.1.0.250205__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of criteo-api-retailmedia-sdk might be problematic. Click here for more details.

@@ -1,269 +0,0 @@
1
- """
2
- Criteo API
3
-
4
- Criteo API - RetailMedia # noqa: E501
5
-
6
- The version of the OpenAPI document: 2025-01
7
- Generated by: https://openapi-generator.tech
8
- """
9
-
10
-
11
- import re # noqa: F401
12
- import sys # noqa: F401
13
-
14
- from criteo_api_retailmedia_v2025_01.model_utils import ( # noqa: F401
15
- ApiTypeError,
16
- ModelComposed,
17
- ModelNormal,
18
- ModelSimple,
19
- cached_property,
20
- change_keys_js_to_python,
21
- convert_js_args_to_python_args,
22
- date,
23
- datetime,
24
- file_type,
25
- none_type,
26
- validate_get_composed_info,
27
- OpenApiModel
28
- )
29
- from criteo_api_retailmedia_v2025_01.exceptions import ApiAttributeError
30
-
31
-
32
-
33
- class BrandPreview(ModelNormal):
34
- """NOTE: This class is auto generated by OpenAPI Generator.
35
- Ref: https://openapi-generator.tech
36
-
37
- Do not edit the class manually.
38
-
39
- Attributes:
40
- allowed_values (dict): The key is the tuple path to the attribute
41
- and the for var_name this is (var_name,). The value is a dict
42
- with a capitalized key describing the allowed value and an allowed
43
- value. These dicts store the allowed enum values.
44
- attribute_map (dict): The key is attribute name
45
- and the value is json key in definition.
46
- discriminator_value_class_map (dict): A dict to go from the discriminator
47
- variable value to the discriminator class name.
48
- validations (dict): The key is the tuple path to the attribute
49
- and the for var_name this is (var_name,). The value is a dict
50
- that stores validations for max_length, min_length, max_items,
51
- min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum,
52
- inclusive_minimum, and regex.
53
- additional_properties_type (tuple): A tuple of classes accepted
54
- as additional properties values.
55
- """
56
-
57
- allowed_values = {
58
- }
59
-
60
- validations = {
61
- }
62
-
63
- @cached_property
64
- def additional_properties_type():
65
- """
66
- This must be a method because a model may have properties that are
67
- of type self, this must run after the class is loaded
68
- """
69
- return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501
70
-
71
- _nullable = False
72
-
73
- @cached_property
74
- def openapi_types():
75
- """
76
- This must be a method because a model may have properties that are
77
- of type self, this must run after the class is loaded
78
-
79
- Returns
80
- openapi_types (dict): The key is attribute name
81
- and the value is attribute type.
82
- """
83
- return {
84
- 'name': (str,), # noqa: E501
85
- }
86
-
87
- @cached_property
88
- def discriminator():
89
- return None
90
-
91
-
92
- attribute_map = {
93
- 'name': 'name', # noqa: E501
94
- }
95
-
96
- read_only_vars = {
97
- }
98
-
99
- _composed_schemas = {}
100
-
101
- @classmethod
102
- @convert_js_args_to_python_args
103
- def _from_openapi_data(cls, name, *args, **kwargs): # noqa: E501
104
- """BrandPreview - a model defined in OpenAPI
105
-
106
- Args:
107
- name (str): Brand Name
108
-
109
- Keyword Args:
110
- _check_type (bool): if True, values for parameters in openapi_types
111
- will be type checked and a TypeError will be
112
- raised if the wrong type is input.
113
- Defaults to True
114
- _path_to_item (tuple/list): This is a list of keys or values to
115
- drill down to the model in received_data
116
- when deserializing a response
117
- _spec_property_naming (bool): True if the variable names in the input data
118
- are serialized names, as specified in the OpenAPI document.
119
- False if the variable names in the input data
120
- are pythonic names, e.g. snake case (default)
121
- _configuration (Configuration): the instance to use when
122
- deserializing a file_type parameter.
123
- If passed, type conversion is attempted
124
- If omitted no type conversion is done.
125
- _visited_composed_classes (tuple): This stores a tuple of
126
- classes that we have traveled through so that
127
- if we see that class again we will not use its
128
- discriminator again.
129
- When traveling through a discriminator, the
130
- composed schema that is
131
- is traveled through is added to this set.
132
- For example if Animal has a discriminator
133
- petType and we pass in "Dog", and the class Dog
134
- allOf includes Animal, we move through Animal
135
- once using the discriminator, and pick Dog.
136
- Then in Dog, we will make an instance of the
137
- Animal class but this time we won't travel
138
- through its discriminator because we passed in
139
- _visited_composed_classes = (Animal,)
140
- """
141
-
142
- _check_type = kwargs.pop('_check_type', True)
143
- _spec_property_naming = kwargs.pop('_spec_property_naming', True)
144
- _path_to_item = kwargs.pop('_path_to_item', ())
145
- _configuration = kwargs.pop('_configuration', None)
146
- _visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
147
-
148
- self = super(OpenApiModel, cls).__new__(cls)
149
-
150
- if args:
151
- for arg in args:
152
- if isinstance(arg, dict):
153
- kwargs.update(arg)
154
- else:
155
- raise ApiTypeError(
156
- "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
157
- args,
158
- self.__class__.__name__,
159
- ),
160
- path_to_item=_path_to_item,
161
- valid_classes=(self.__class__,),
162
- )
163
-
164
- self._data_store = {}
165
- self._check_type = _check_type
166
- self._spec_property_naming = _spec_property_naming
167
- self._path_to_item = _path_to_item
168
- self._configuration = _configuration
169
- self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
170
-
171
- self.name = name
172
- for var_name, var_value in kwargs.items():
173
- if var_name not in self.attribute_map and \
174
- self._configuration is not None and \
175
- self._configuration.discard_unknown_keys and \
176
- self.additional_properties_type is None:
177
- # discard variable.
178
- continue
179
- setattr(self, var_name, var_value)
180
- return self
181
-
182
- required_properties = set([
183
- '_data_store',
184
- '_check_type',
185
- '_spec_property_naming',
186
- '_path_to_item',
187
- '_configuration',
188
- '_visited_composed_classes',
189
- ])
190
-
191
- @convert_js_args_to_python_args
192
- def __init__(self, name, *args, **kwargs): # noqa: E501
193
- """BrandPreview - a model defined in OpenAPI
194
-
195
- Args:
196
- name (str): Brand Name
197
-
198
- Keyword Args:
199
- _check_type (bool): if True, values for parameters in openapi_types
200
- will be type checked and a TypeError will be
201
- raised if the wrong type is input.
202
- Defaults to True
203
- _path_to_item (tuple/list): This is a list of keys or values to
204
- drill down to the model in received_data
205
- when deserializing a response
206
- _spec_property_naming (bool): True if the variable names in the input data
207
- are serialized names, as specified in the OpenAPI document.
208
- False if the variable names in the input data
209
- are pythonic names, e.g. snake case (default)
210
- _configuration (Configuration): the instance to use when
211
- deserializing a file_type parameter.
212
- If passed, type conversion is attempted
213
- If omitted no type conversion is done.
214
- _visited_composed_classes (tuple): This stores a tuple of
215
- classes that we have traveled through so that
216
- if we see that class again we will not use its
217
- discriminator again.
218
- When traveling through a discriminator, the
219
- composed schema that is
220
- is traveled through is added to this set.
221
- For example if Animal has a discriminator
222
- petType and we pass in "Dog", and the class Dog
223
- allOf includes Animal, we move through Animal
224
- once using the discriminator, and pick Dog.
225
- Then in Dog, we will make an instance of the
226
- Animal class but this time we won't travel
227
- through its discriminator because we passed in
228
- _visited_composed_classes = (Animal,)
229
- """
230
-
231
- _check_type = kwargs.pop('_check_type', True)
232
- _spec_property_naming = kwargs.pop('_spec_property_naming', False)
233
- _path_to_item = kwargs.pop('_path_to_item', ())
234
- _configuration = kwargs.pop('_configuration', None)
235
- _visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
236
-
237
- if args:
238
- for arg in args:
239
- if isinstance(arg, dict):
240
- kwargs.update(arg)
241
- else:
242
- raise ApiTypeError(
243
- "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
244
- args,
245
- self.__class__.__name__,
246
- ),
247
- path_to_item=_path_to_item,
248
- valid_classes=(self.__class__,),
249
- )
250
-
251
- self._data_store = {}
252
- self._check_type = _check_type
253
- self._spec_property_naming = _spec_property_naming
254
- self._path_to_item = _path_to_item
255
- self._configuration = _configuration
256
- self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
257
-
258
- self.name = name
259
- for var_name, var_value in kwargs.items():
260
- if var_name not in self.attribute_map and \
261
- self._configuration is not None and \
262
- self._configuration.discard_unknown_keys and \
263
- self.additional_properties_type is None:
264
- # discard variable.
265
- continue
266
- setattr(self, var_name, var_value)
267
- if var_name in self.read_only_vars:
268
- raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate "
269
- f"class with read only attributes.")
@@ -1,281 +0,0 @@
1
- """
2
- Criteo API
3
-
4
- Criteo API - RetailMedia # noqa: E501
5
-
6
- The version of the OpenAPI document: 2025-01
7
- Generated by: https://openapi-generator.tech
8
- """
9
-
10
-
11
- import re # noqa: F401
12
- import sys # noqa: F401
13
-
14
- from criteo_api_retailmedia_v2025_01.model_utils import ( # noqa: F401
15
- ApiTypeError,
16
- ModelComposed,
17
- ModelNormal,
18
- ModelSimple,
19
- cached_property,
20
- change_keys_js_to_python,
21
- convert_js_args_to_python_args,
22
- date,
23
- datetime,
24
- file_type,
25
- none_type,
26
- validate_get_composed_info,
27
- OpenApiModel
28
- )
29
- from criteo_api_retailmedia_v2025_01.exceptions import ApiAttributeError
30
-
31
-
32
- def lazy_import():
33
- from criteo_api_retailmedia_v2025_01.model.problem_details import ProblemDetails
34
- from criteo_api_retailmedia_v2025_01.model.resource_of_brand_preview import ResourceOfBrandPreview
35
- globals()['ProblemDetails'] = ProblemDetails
36
- globals()['ResourceOfBrandPreview'] = ResourceOfBrandPreview
37
-
38
-
39
- class BrandPreviewListResponse(ModelNormal):
40
- """NOTE: This class is auto generated by OpenAPI Generator.
41
- Ref: https://openapi-generator.tech
42
-
43
- Do not edit the class manually.
44
-
45
- Attributes:
46
- allowed_values (dict): The key is the tuple path to the attribute
47
- and the for var_name this is (var_name,). The value is a dict
48
- with a capitalized key describing the allowed value and an allowed
49
- value. These dicts store the allowed enum values.
50
- attribute_map (dict): The key is attribute name
51
- and the value is json key in definition.
52
- discriminator_value_class_map (dict): A dict to go from the discriminator
53
- variable value to the discriminator class name.
54
- validations (dict): The key is the tuple path to the attribute
55
- and the for var_name this is (var_name,). The value is a dict
56
- that stores validations for max_length, min_length, max_items,
57
- min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum,
58
- inclusive_minimum, and regex.
59
- additional_properties_type (tuple): A tuple of classes accepted
60
- as additional properties values.
61
- """
62
-
63
- allowed_values = {
64
- }
65
-
66
- validations = {
67
- }
68
-
69
- @cached_property
70
- def additional_properties_type():
71
- """
72
- This must be a method because a model may have properties that are
73
- of type self, this must run after the class is loaded
74
- """
75
- lazy_import()
76
- return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501
77
-
78
- _nullable = False
79
-
80
- @cached_property
81
- def openapi_types():
82
- """
83
- This must be a method because a model may have properties that are
84
- of type self, this must run after the class is loaded
85
-
86
- Returns
87
- openapi_types (dict): The key is attribute name
88
- and the value is attribute type.
89
- """
90
- lazy_import()
91
- return {
92
- 'data': ([ResourceOfBrandPreview],), # noqa: E501
93
- 'warnings': ([ProblemDetails],), # noqa: E501
94
- 'errors': ([ProblemDetails],), # noqa: E501
95
- }
96
-
97
- @cached_property
98
- def discriminator():
99
- return None
100
-
101
-
102
- attribute_map = {
103
- 'data': 'data', # noqa: E501
104
- 'warnings': 'warnings', # noqa: E501
105
- 'errors': 'errors', # noqa: E501
106
- }
107
-
108
- read_only_vars = {
109
- 'warnings', # noqa: E501
110
- 'errors', # noqa: E501
111
- }
112
-
113
- _composed_schemas = {}
114
-
115
- @classmethod
116
- @convert_js_args_to_python_args
117
- def _from_openapi_data(cls, *args, **kwargs): # noqa: E501
118
- """BrandPreviewListResponse - a model defined in OpenAPI
119
-
120
- Keyword Args:
121
- _check_type (bool): if True, values for parameters in openapi_types
122
- will be type checked and a TypeError will be
123
- raised if the wrong type is input.
124
- Defaults to True
125
- _path_to_item (tuple/list): This is a list of keys or values to
126
- drill down to the model in received_data
127
- when deserializing a response
128
- _spec_property_naming (bool): True if the variable names in the input data
129
- are serialized names, as specified in the OpenAPI document.
130
- False if the variable names in the input data
131
- are pythonic names, e.g. snake case (default)
132
- _configuration (Configuration): the instance to use when
133
- deserializing a file_type parameter.
134
- If passed, type conversion is attempted
135
- If omitted no type conversion is done.
136
- _visited_composed_classes (tuple): This stores a tuple of
137
- classes that we have traveled through so that
138
- if we see that class again we will not use its
139
- discriminator again.
140
- When traveling through a discriminator, the
141
- composed schema that is
142
- is traveled through is added to this set.
143
- For example if Animal has a discriminator
144
- petType and we pass in "Dog", and the class Dog
145
- allOf includes Animal, we move through Animal
146
- once using the discriminator, and pick Dog.
147
- Then in Dog, we will make an instance of the
148
- Animal class but this time we won't travel
149
- through its discriminator because we passed in
150
- _visited_composed_classes = (Animal,)
151
- data ([ResourceOfBrandPreview]): [optional] # noqa: E501
152
- warnings ([ProblemDetails]): [optional] # noqa: E501
153
- errors ([ProblemDetails]): [optional] # noqa: E501
154
- """
155
-
156
- _check_type = kwargs.pop('_check_type', True)
157
- _spec_property_naming = kwargs.pop('_spec_property_naming', True)
158
- _path_to_item = kwargs.pop('_path_to_item', ())
159
- _configuration = kwargs.pop('_configuration', None)
160
- _visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
161
-
162
- self = super(OpenApiModel, cls).__new__(cls)
163
-
164
- if args:
165
- for arg in args:
166
- if isinstance(arg, dict):
167
- kwargs.update(arg)
168
- else:
169
- raise ApiTypeError(
170
- "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
171
- args,
172
- self.__class__.__name__,
173
- ),
174
- path_to_item=_path_to_item,
175
- valid_classes=(self.__class__,),
176
- )
177
-
178
- self._data_store = {}
179
- self._check_type = _check_type
180
- self._spec_property_naming = _spec_property_naming
181
- self._path_to_item = _path_to_item
182
- self._configuration = _configuration
183
- self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
184
-
185
- for var_name, var_value in kwargs.items():
186
- if var_name not in self.attribute_map and \
187
- self._configuration is not None and \
188
- self._configuration.discard_unknown_keys and \
189
- self.additional_properties_type is None:
190
- # discard variable.
191
- continue
192
- setattr(self, var_name, var_value)
193
- return self
194
-
195
- required_properties = set([
196
- '_data_store',
197
- '_check_type',
198
- '_spec_property_naming',
199
- '_path_to_item',
200
- '_configuration',
201
- '_visited_composed_classes',
202
- ])
203
-
204
- @convert_js_args_to_python_args
205
- def __init__(self, *args, **kwargs): # noqa: E501
206
- """BrandPreviewListResponse - a model defined in OpenAPI
207
-
208
- Keyword Args:
209
- _check_type (bool): if True, values for parameters in openapi_types
210
- will be type checked and a TypeError will be
211
- raised if the wrong type is input.
212
- Defaults to True
213
- _path_to_item (tuple/list): This is a list of keys or values to
214
- drill down to the model in received_data
215
- when deserializing a response
216
- _spec_property_naming (bool): True if the variable names in the input data
217
- are serialized names, as specified in the OpenAPI document.
218
- False if the variable names in the input data
219
- are pythonic names, e.g. snake case (default)
220
- _configuration (Configuration): the instance to use when
221
- deserializing a file_type parameter.
222
- If passed, type conversion is attempted
223
- If omitted no type conversion is done.
224
- _visited_composed_classes (tuple): This stores a tuple of
225
- classes that we have traveled through so that
226
- if we see that class again we will not use its
227
- discriminator again.
228
- When traveling through a discriminator, the
229
- composed schema that is
230
- is traveled through is added to this set.
231
- For example if Animal has a discriminator
232
- petType and we pass in "Dog", and the class Dog
233
- allOf includes Animal, we move through Animal
234
- once using the discriminator, and pick Dog.
235
- Then in Dog, we will make an instance of the
236
- Animal class but this time we won't travel
237
- through its discriminator because we passed in
238
- _visited_composed_classes = (Animal,)
239
- data ([ResourceOfBrandPreview]): [optional] # noqa: E501
240
- warnings ([ProblemDetails]): [optional] # noqa: E501
241
- errors ([ProblemDetails]): [optional] # noqa: E501
242
- """
243
-
244
- _check_type = kwargs.pop('_check_type', True)
245
- _spec_property_naming = kwargs.pop('_spec_property_naming', False)
246
- _path_to_item = kwargs.pop('_path_to_item', ())
247
- _configuration = kwargs.pop('_configuration', None)
248
- _visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
249
-
250
- if args:
251
- for arg in args:
252
- if isinstance(arg, dict):
253
- kwargs.update(arg)
254
- else:
255
- raise ApiTypeError(
256
- "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
257
- args,
258
- self.__class__.__name__,
259
- ),
260
- path_to_item=_path_to_item,
261
- valid_classes=(self.__class__,),
262
- )
263
-
264
- self._data_store = {}
265
- self._check_type = _check_type
266
- self._spec_property_naming = _spec_property_naming
267
- self._path_to_item = _path_to_item
268
- self._configuration = _configuration
269
- self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
270
-
271
- for var_name, var_value in kwargs.items():
272
- if var_name not in self.attribute_map and \
273
- self._configuration is not None and \
274
- self._configuration.discard_unknown_keys and \
275
- self.additional_properties_type is None:
276
- # discard variable.
277
- continue
278
- setattr(self, var_name, var_value)
279
- if var_name in self.read_only_vars:
280
- raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate "
281
- f"class with read only attributes.")