criteo-api-retailmedia-sdk 0.0.250409__py3-none-any.whl → 0.0.250606__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.
- criteo_api_retailmedia_preview/__init__.py +1 -1
- criteo_api_retailmedia_preview/api/accounts_api.py +3 -147
- criteo_api_retailmedia_preview/api/analytics_api.py +1 -1
- criteo_api_retailmedia_preview/api/audience_api.py +1204 -135
- criteo_api_retailmedia_preview/api/campaign_api.py +741 -104
- criteo_api_retailmedia_preview/api_client.py +1 -1
- criteo_api_retailmedia_preview/configuration.py +1 -1
- criteo_api_retailmedia_preview/model/account_fees_update_request.py +4 -0
- criteo_api_retailmedia_preview/model/async_accounts_report.py +6 -6
- criteo_api_retailmedia_preview/model/async_campaigns_report.py +4 -4
- criteo_api_retailmedia_preview/model/async_line_items_report.py +4 -4
- criteo_api_retailmedia_preview/model/async_offsite_report.py +25 -18
- criteo_api_retailmedia_preview/model/brand_id_search_request.py +7 -1
- criteo_api_retailmedia_preview/model/brand_id_search_result.py +7 -1
- criteo_api_retailmedia_preview/model/categories_search_request_v1.py +270 -0
- criteo_api_retailmedia_preview/model/entity_resource_brand_id_search_result.py +8 -1
- criteo_api_retailmedia_preview/model/entity_resource_category202204.py +277 -0
- criteo_api_retailmedia_preview/model/entity_resource_collection_outcome_brand_id_search_result_paging_offset_limit_metadata.py +8 -1
- criteo_api_retailmedia_preview/model/entity_resource_collection_outcome_category202204.py +281 -0
- criteo_api_retailmedia_preview/model/entity_resource_collection_outcome_category202204_metadata.py +287 -0
- criteo_api_retailmedia_preview/model/entity_resource_of_sponsored_products_line_item.py +270 -0
- criteo_api_retailmedia_preview/model/entity_resource_outcome_of_sponsored_products_line_item.py +274 -0
- criteo_api_retailmedia_preview/model/{input_keywords.py → flight_leg.py} +39 -17
- criteo_api_retailmedia_preview/model/{recommended_keywords_result.py → flight_schedule.py} +9 -13
- criteo_api_retailmedia_preview/model/nillable_decimal.py +263 -0
- criteo_api_retailmedia_preview/model/page_of_sponsored_products_line_item.py +276 -0
- criteo_api_retailmedia_preview/model/paging_offset_limit_metadata.py +7 -1
- criteo_api_retailmedia_preview/model/{grant_consent_model.py → recommended_categories_request_v1.py} +14 -21
- criteo_api_retailmedia_preview/model/recommended_keywords_request_v1.py +266 -0
- criteo_api_retailmedia_preview/model/recommended_keywords_response_v1.py +263 -0
- criteo_api_retailmedia_preview/model/{line_item_bid_multipliers_v2_request.py → rm_audience_bulk_create_input_v1.py} +9 -9
- criteo_api_retailmedia_preview/model/{grant_consent_input.py → rm_audience_bulk_delete_input_v1.py} +8 -8
- criteo_api_retailmedia_preview/model/rm_audience_bulk_update_input_v1.py +269 -0
- criteo_api_retailmedia_preview/model/rm_audience_compute_sizes_entity_v1.py +272 -0
- criteo_api_retailmedia_preview/model/rm_audience_compute_sizes_entity_v1_resource.py +273 -0
- criteo_api_retailmedia_preview/model/rm_audience_compute_sizes_input_v1.py +269 -0
- criteo_api_retailmedia_preview/model/rm_audience_create_entity_v1.py +291 -0
- criteo_api_retailmedia_preview/model/{grant_consent_model_value_resource.py → rm_audience_create_entity_v1_resource.py} +8 -8
- criteo_api_retailmedia_preview/model/rm_audience_delete_entity_v1_resource.py +271 -0
- criteo_api_retailmedia_preview/model/{value_resource_outcome_of_recommended_keywords_result.py → rm_audience_entity_v1_list_response.py} +16 -9
- criteo_api_retailmedia_preview/model/rm_audience_estimate_size_entity_v1.py +282 -0
- criteo_api_retailmedia_preview/model/rm_audience_estimate_size_entity_v1_resource.py +273 -0
- criteo_api_retailmedia_preview/model/rm_audience_estimate_size_input_v1.py +269 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_compute_size_entity_v1.py +272 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_compute_size_entity_v1_resource.py +273 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_compute_sizes_input_v1.py +269 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_create_entity_v1.py +6 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_estimate_size_entity_v1.py +282 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_estimate_size_entity_v1_resource.py +273 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_estimate_size_input_v1.py +269 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_size_entity_v1.py +267 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_size_entity_v1_list_response.py +281 -0
- criteo_api_retailmedia_preview/model/{resource_of_line_item_bid_multipliers_v2.py → rm_audience_segment_size_entity_v1_resource.py} +11 -11
- criteo_api_retailmedia_preview/model/rm_audience_segment_size_estimation_v1.py +267 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_size_estimation_v1_resource.py +273 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_size_estimation_v1_response.py +281 -0
- criteo_api_retailmedia_preview/model/rm_audience_segment_update_entity_v1.py +6 -0
- criteo_api_retailmedia_preview/model/rm_audience_size_entity_v1.py +267 -0
- criteo_api_retailmedia_preview/model/rm_audience_size_entity_v1_list_response.py +281 -0
- criteo_api_retailmedia_preview/model/rm_audience_size_entity_v1_resource.py +277 -0
- criteo_api_retailmedia_preview/model/rm_audience_size_estimation_v1.py +267 -0
- criteo_api_retailmedia_preview/model/rm_audience_size_estimation_v1_resource.py +273 -0
- criteo_api_retailmedia_preview/model/{line_item_bid_multipliers_v2_response.py → rm_audience_size_estimation_v1_response.py} +9 -9
- criteo_api_retailmedia_preview/model/rm_audience_update_entity_v1.py +279 -0
- criteo_api_retailmedia_preview/model/{json_api_body_with_id_of_int64_and_line_item_bid_multipliers_v2_and_line_item_bid_multipliers_v2.py → rm_audience_update_entity_v1_resource.py} +17 -19
- criteo_api_retailmedia_preview/model/rm_events_create_v1.py +305 -0
- criteo_api_retailmedia_preview/model/rm_events_estimation_v1.py +305 -0
- criteo_api_retailmedia_preview/model/rm_events_update_v1.py +307 -0
- criteo_api_retailmedia_preview/model/sku_slim_data_preview.py +6 -6
- criteo_api_retailmedia_preview/model/sponsored_products_line_item.py +387 -0
- criteo_api_retailmedia_preview/model/{json_api_single_response_of_line_item_bid_multipliers_v2.py → sponsored_products_line_item_create_request_model.py} +81 -33
- criteo_api_retailmedia_preview/model/{keywords.py → sponsored_products_line_item_update_request_model.py} +82 -44
- criteo_api_retailmedia_preview/model/sync_attributed_transactions_report.py +2 -2
- criteo_api_retailmedia_preview/model/sync_campaigns_report.py +4 -4
- criteo_api_retailmedia_preview/model/sync_line_items_report.py +4 -4
- criteo_api_retailmedia_preview/model/value_resource_brand_id_search_request.py +8 -1
- criteo_api_retailmedia_preview/model/value_resource_categories_search_request_v1.py +273 -0
- criteo_api_retailmedia_preview/model/{value_resource_collection_outcome_private_market_account_fees.py → value_resource_collection_outcome_private_market_account_fees_and_metadata.py} +9 -3
- criteo_api_retailmedia_preview/model/value_resource_input_brand_id_search_request.py +8 -1
- criteo_api_retailmedia_preview/model/value_resource_input_categories_search_request_v1.py +269 -0
- criteo_api_retailmedia_preview/model/value_resource_input_of_sponsored_products_line_item_update_request_model.py +262 -0
- criteo_api_retailmedia_preview/model/value_resource_input_recommended_categories_request_v1.py +269 -0
- criteo_api_retailmedia_preview/model/value_resource_input_recommended_keywords_request_v1.py +262 -0
- criteo_api_retailmedia_preview/model/value_resource_of_sponsored_products_line_item_update_request_model.py +266 -0
- criteo_api_retailmedia_preview/model/value_resource_outcome_recommended_keywords_response_v1.py +274 -0
- criteo_api_retailmedia_preview/model/value_resource_recommended_categories_request_v1.py +273 -0
- criteo_api_retailmedia_preview/model/value_resource_recommended_keywords_request_v1.py +266 -0
- criteo_api_retailmedia_preview/model/{value_resource_of_recommended_keywords_result.py → value_resource_recommended_keywords_response_v1.py} +10 -10
- criteo_api_retailmedia_preview/models/__init__.py +63 -17
- {criteo_api_retailmedia_sdk-0.0.250409.dist-info → criteo_api_retailmedia_sdk-0.0.250606.dist-info}/METADATA +3 -3
- {criteo_api_retailmedia_sdk-0.0.250409.dist-info → criteo_api_retailmedia_sdk-0.0.250606.dist-info}/RECORD +93 -47
- {criteo_api_retailmedia_sdk-0.0.250409.dist-info → criteo_api_retailmedia_sdk-0.0.250606.dist-info}/WHEEL +1 -1
- criteo_api_retailmedia_preview/model/common_error.py +0 -301
- criteo_api_retailmedia_preview/model/common_warning.py +0 -301
- criteo_api_retailmedia_preview/model/external_line_item_bid_multipliers_v2.py +0 -307
- {criteo_api_retailmedia_sdk-0.0.250409.dist-info → criteo_api_retailmedia_sdk-0.0.250606.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,263 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Criteo API
|
|
3
|
+
|
|
4
|
+
Criteo API - RetailMedia # noqa: E501
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: Preview
|
|
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_preview.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_preview.exceptions import ApiAttributeError
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
class NillableDecimal(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 = True
|
|
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
|
+
'value': (float, none_type,), # noqa: E501
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
@cached_property
|
|
88
|
+
def discriminator():
|
|
89
|
+
return None
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
attribute_map = {
|
|
93
|
+
'value': 'value', # 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, *args, **kwargs): # noqa: E501
|
|
104
|
+
"""NillableDecimal - a model defined in OpenAPI
|
|
105
|
+
|
|
106
|
+
Keyword Args:
|
|
107
|
+
_check_type (bool): if True, values for parameters in openapi_types
|
|
108
|
+
will be type checked and a TypeError will be
|
|
109
|
+
raised if the wrong type is input.
|
|
110
|
+
Defaults to True
|
|
111
|
+
_path_to_item (tuple/list): This is a list of keys or values to
|
|
112
|
+
drill down to the model in received_data
|
|
113
|
+
when deserializing a response
|
|
114
|
+
_spec_property_naming (bool): True if the variable names in the input data
|
|
115
|
+
are serialized names, as specified in the OpenAPI document.
|
|
116
|
+
False if the variable names in the input data
|
|
117
|
+
are pythonic names, e.g. snake case (default)
|
|
118
|
+
_configuration (Configuration): the instance to use when
|
|
119
|
+
deserializing a file_type parameter.
|
|
120
|
+
If passed, type conversion is attempted
|
|
121
|
+
If omitted no type conversion is done.
|
|
122
|
+
_visited_composed_classes (tuple): This stores a tuple of
|
|
123
|
+
classes that we have traveled through so that
|
|
124
|
+
if we see that class again we will not use its
|
|
125
|
+
discriminator again.
|
|
126
|
+
When traveling through a discriminator, the
|
|
127
|
+
composed schema that is
|
|
128
|
+
is traveled through is added to this set.
|
|
129
|
+
For example if Animal has a discriminator
|
|
130
|
+
petType and we pass in "Dog", and the class Dog
|
|
131
|
+
allOf includes Animal, we move through Animal
|
|
132
|
+
once using the discriminator, and pick Dog.
|
|
133
|
+
Then in Dog, we will make an instance of the
|
|
134
|
+
Animal class but this time we won't travel
|
|
135
|
+
through its discriminator because we passed in
|
|
136
|
+
_visited_composed_classes = (Animal,)
|
|
137
|
+
value (float, none_type): The value. If missing or null the value is set to \"null\". [optional] # noqa: E501
|
|
138
|
+
"""
|
|
139
|
+
|
|
140
|
+
_check_type = kwargs.pop('_check_type', True)
|
|
141
|
+
_spec_property_naming = kwargs.pop('_spec_property_naming', True)
|
|
142
|
+
_path_to_item = kwargs.pop('_path_to_item', ())
|
|
143
|
+
_configuration = kwargs.pop('_configuration', None)
|
|
144
|
+
_visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
|
|
145
|
+
|
|
146
|
+
self = super(OpenApiModel, cls).__new__(cls)
|
|
147
|
+
|
|
148
|
+
if args:
|
|
149
|
+
for arg in args:
|
|
150
|
+
if isinstance(arg, dict):
|
|
151
|
+
kwargs.update(arg)
|
|
152
|
+
else:
|
|
153
|
+
raise ApiTypeError(
|
|
154
|
+
"Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
|
|
155
|
+
args,
|
|
156
|
+
self.__class__.__name__,
|
|
157
|
+
),
|
|
158
|
+
path_to_item=_path_to_item,
|
|
159
|
+
valid_classes=(self.__class__,),
|
|
160
|
+
)
|
|
161
|
+
|
|
162
|
+
self._data_store = {}
|
|
163
|
+
self._check_type = _check_type
|
|
164
|
+
self._spec_property_naming = _spec_property_naming
|
|
165
|
+
self._path_to_item = _path_to_item
|
|
166
|
+
self._configuration = _configuration
|
|
167
|
+
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
|
|
168
|
+
|
|
169
|
+
for var_name, var_value in kwargs.items():
|
|
170
|
+
if var_name not in self.attribute_map and \
|
|
171
|
+
self._configuration is not None and \
|
|
172
|
+
self._configuration.discard_unknown_keys and \
|
|
173
|
+
self.additional_properties_type is None:
|
|
174
|
+
# discard variable.
|
|
175
|
+
continue
|
|
176
|
+
setattr(self, var_name, var_value)
|
|
177
|
+
return self
|
|
178
|
+
|
|
179
|
+
required_properties = set([
|
|
180
|
+
'_data_store',
|
|
181
|
+
'_check_type',
|
|
182
|
+
'_spec_property_naming',
|
|
183
|
+
'_path_to_item',
|
|
184
|
+
'_configuration',
|
|
185
|
+
'_visited_composed_classes',
|
|
186
|
+
])
|
|
187
|
+
|
|
188
|
+
@convert_js_args_to_python_args
|
|
189
|
+
def __init__(self, *args, **kwargs): # noqa: E501
|
|
190
|
+
"""NillableDecimal - a model defined in OpenAPI
|
|
191
|
+
|
|
192
|
+
Keyword Args:
|
|
193
|
+
_check_type (bool): if True, values for parameters in openapi_types
|
|
194
|
+
will be type checked and a TypeError will be
|
|
195
|
+
raised if the wrong type is input.
|
|
196
|
+
Defaults to True
|
|
197
|
+
_path_to_item (tuple/list): This is a list of keys or values to
|
|
198
|
+
drill down to the model in received_data
|
|
199
|
+
when deserializing a response
|
|
200
|
+
_spec_property_naming (bool): True if the variable names in the input data
|
|
201
|
+
are serialized names, as specified in the OpenAPI document.
|
|
202
|
+
False if the variable names in the input data
|
|
203
|
+
are pythonic names, e.g. snake case (default)
|
|
204
|
+
_configuration (Configuration): the instance to use when
|
|
205
|
+
deserializing a file_type parameter.
|
|
206
|
+
If passed, type conversion is attempted
|
|
207
|
+
If omitted no type conversion is done.
|
|
208
|
+
_visited_composed_classes (tuple): This stores a tuple of
|
|
209
|
+
classes that we have traveled through so that
|
|
210
|
+
if we see that class again we will not use its
|
|
211
|
+
discriminator again.
|
|
212
|
+
When traveling through a discriminator, the
|
|
213
|
+
composed schema that is
|
|
214
|
+
is traveled through is added to this set.
|
|
215
|
+
For example if Animal has a discriminator
|
|
216
|
+
petType and we pass in "Dog", and the class Dog
|
|
217
|
+
allOf includes Animal, we move through Animal
|
|
218
|
+
once using the discriminator, and pick Dog.
|
|
219
|
+
Then in Dog, we will make an instance of the
|
|
220
|
+
Animal class but this time we won't travel
|
|
221
|
+
through its discriminator because we passed in
|
|
222
|
+
_visited_composed_classes = (Animal,)
|
|
223
|
+
value (float, none_type): The value. If missing or null the value is set to \"null\". [optional] # noqa: E501
|
|
224
|
+
"""
|
|
225
|
+
|
|
226
|
+
_check_type = kwargs.pop('_check_type', True)
|
|
227
|
+
_spec_property_naming = kwargs.pop('_spec_property_naming', False)
|
|
228
|
+
_path_to_item = kwargs.pop('_path_to_item', ())
|
|
229
|
+
_configuration = kwargs.pop('_configuration', None)
|
|
230
|
+
_visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
|
|
231
|
+
|
|
232
|
+
if args:
|
|
233
|
+
for arg in args:
|
|
234
|
+
if isinstance(arg, dict):
|
|
235
|
+
kwargs.update(arg)
|
|
236
|
+
else:
|
|
237
|
+
raise ApiTypeError(
|
|
238
|
+
"Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
|
|
239
|
+
args,
|
|
240
|
+
self.__class__.__name__,
|
|
241
|
+
),
|
|
242
|
+
path_to_item=_path_to_item,
|
|
243
|
+
valid_classes=(self.__class__,),
|
|
244
|
+
)
|
|
245
|
+
|
|
246
|
+
self._data_store = {}
|
|
247
|
+
self._check_type = _check_type
|
|
248
|
+
self._spec_property_naming = _spec_property_naming
|
|
249
|
+
self._path_to_item = _path_to_item
|
|
250
|
+
self._configuration = _configuration
|
|
251
|
+
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
|
|
252
|
+
|
|
253
|
+
for var_name, var_value in kwargs.items():
|
|
254
|
+
if var_name not in self.attribute_map and \
|
|
255
|
+
self._configuration is not None and \
|
|
256
|
+
self._configuration.discard_unknown_keys and \
|
|
257
|
+
self.additional_properties_type is None:
|
|
258
|
+
# discard variable.
|
|
259
|
+
continue
|
|
260
|
+
setattr(self, var_name, var_value)
|
|
261
|
+
if var_name in self.read_only_vars:
|
|
262
|
+
raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate "
|
|
263
|
+
f"class with read only attributes.")
|
|
@@ -0,0 +1,276 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Criteo API
|
|
3
|
+
|
|
4
|
+
Criteo API - RetailMedia # noqa: E501
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: Preview
|
|
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_preview.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_preview.exceptions import ApiAttributeError
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
def lazy_import():
|
|
33
|
+
from criteo_api_retailmedia_preview.model.metadata import Metadata
|
|
34
|
+
from criteo_api_retailmedia_preview.model.sponsored_products_line_item import SponsoredProductsLineItem
|
|
35
|
+
globals()['Metadata'] = Metadata
|
|
36
|
+
globals()['SponsoredProductsLineItem'] = SponsoredProductsLineItem
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
class PageOfSponsoredProductsLineItem(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
|
+
additional_properties_type = None
|
|
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
|
+
lazy_import()
|
|
84
|
+
return {
|
|
85
|
+
'data': ([SponsoredProductsLineItem],), # noqa: E501
|
|
86
|
+
'meta': (Metadata,), # noqa: E501
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
@cached_property
|
|
90
|
+
def discriminator():
|
|
91
|
+
return None
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
attribute_map = {
|
|
95
|
+
'data': 'data', # noqa: E501
|
|
96
|
+
'meta': 'meta', # noqa: E501
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
read_only_vars = {
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
_composed_schemas = {}
|
|
103
|
+
|
|
104
|
+
@classmethod
|
|
105
|
+
@convert_js_args_to_python_args
|
|
106
|
+
def _from_openapi_data(cls, data, meta, *args, **kwargs): # noqa: E501
|
|
107
|
+
"""PageOfSponsoredProductsLineItem - a model defined in OpenAPI
|
|
108
|
+
|
|
109
|
+
Args:
|
|
110
|
+
data ([SponsoredProductsLineItem]):
|
|
111
|
+
meta (Metadata):
|
|
112
|
+
|
|
113
|
+
Keyword Args:
|
|
114
|
+
_check_type (bool): if True, values for parameters in openapi_types
|
|
115
|
+
will be type checked and a TypeError will be
|
|
116
|
+
raised if the wrong type is input.
|
|
117
|
+
Defaults to True
|
|
118
|
+
_path_to_item (tuple/list): This is a list of keys or values to
|
|
119
|
+
drill down to the model in received_data
|
|
120
|
+
when deserializing a response
|
|
121
|
+
_spec_property_naming (bool): True if the variable names in the input data
|
|
122
|
+
are serialized names, as specified in the OpenAPI document.
|
|
123
|
+
False if the variable names in the input data
|
|
124
|
+
are pythonic names, e.g. snake case (default)
|
|
125
|
+
_configuration (Configuration): the instance to use when
|
|
126
|
+
deserializing a file_type parameter.
|
|
127
|
+
If passed, type conversion is attempted
|
|
128
|
+
If omitted no type conversion is done.
|
|
129
|
+
_visited_composed_classes (tuple): This stores a tuple of
|
|
130
|
+
classes that we have traveled through so that
|
|
131
|
+
if we see that class again we will not use its
|
|
132
|
+
discriminator again.
|
|
133
|
+
When traveling through a discriminator, the
|
|
134
|
+
composed schema that is
|
|
135
|
+
is traveled through is added to this set.
|
|
136
|
+
For example if Animal has a discriminator
|
|
137
|
+
petType and we pass in "Dog", and the class Dog
|
|
138
|
+
allOf includes Animal, we move through Animal
|
|
139
|
+
once using the discriminator, and pick Dog.
|
|
140
|
+
Then in Dog, we will make an instance of the
|
|
141
|
+
Animal class but this time we won't travel
|
|
142
|
+
through its discriminator because we passed in
|
|
143
|
+
_visited_composed_classes = (Animal,)
|
|
144
|
+
"""
|
|
145
|
+
|
|
146
|
+
_check_type = kwargs.pop('_check_type', True)
|
|
147
|
+
_spec_property_naming = kwargs.pop('_spec_property_naming', True)
|
|
148
|
+
_path_to_item = kwargs.pop('_path_to_item', ())
|
|
149
|
+
_configuration = kwargs.pop('_configuration', None)
|
|
150
|
+
_visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
|
|
151
|
+
|
|
152
|
+
self = super(OpenApiModel, cls).__new__(cls)
|
|
153
|
+
|
|
154
|
+
if args:
|
|
155
|
+
for arg in args:
|
|
156
|
+
if isinstance(arg, dict):
|
|
157
|
+
kwargs.update(arg)
|
|
158
|
+
else:
|
|
159
|
+
raise ApiTypeError(
|
|
160
|
+
"Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
|
|
161
|
+
args,
|
|
162
|
+
self.__class__.__name__,
|
|
163
|
+
),
|
|
164
|
+
path_to_item=_path_to_item,
|
|
165
|
+
valid_classes=(self.__class__,),
|
|
166
|
+
)
|
|
167
|
+
|
|
168
|
+
self._data_store = {}
|
|
169
|
+
self._check_type = _check_type
|
|
170
|
+
self._spec_property_naming = _spec_property_naming
|
|
171
|
+
self._path_to_item = _path_to_item
|
|
172
|
+
self._configuration = _configuration
|
|
173
|
+
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
|
|
174
|
+
|
|
175
|
+
self.data = data
|
|
176
|
+
self.meta = meta
|
|
177
|
+
for var_name, var_value in kwargs.items():
|
|
178
|
+
if var_name not in self.attribute_map and \
|
|
179
|
+
self._configuration is not None and \
|
|
180
|
+
self._configuration.discard_unknown_keys and \
|
|
181
|
+
self.additional_properties_type is None:
|
|
182
|
+
# discard variable.
|
|
183
|
+
continue
|
|
184
|
+
setattr(self, var_name, var_value)
|
|
185
|
+
return self
|
|
186
|
+
|
|
187
|
+
required_properties = set([
|
|
188
|
+
'_data_store',
|
|
189
|
+
'_check_type',
|
|
190
|
+
'_spec_property_naming',
|
|
191
|
+
'_path_to_item',
|
|
192
|
+
'_configuration',
|
|
193
|
+
'_visited_composed_classes',
|
|
194
|
+
])
|
|
195
|
+
|
|
196
|
+
@convert_js_args_to_python_args
|
|
197
|
+
def __init__(self, data, meta, *args, **kwargs): # noqa: E501
|
|
198
|
+
"""PageOfSponsoredProductsLineItem - a model defined in OpenAPI
|
|
199
|
+
|
|
200
|
+
Args:
|
|
201
|
+
data ([SponsoredProductsLineItem]):
|
|
202
|
+
meta (Metadata):
|
|
203
|
+
|
|
204
|
+
Keyword Args:
|
|
205
|
+
_check_type (bool): if True, values for parameters in openapi_types
|
|
206
|
+
will be type checked and a TypeError will be
|
|
207
|
+
raised if the wrong type is input.
|
|
208
|
+
Defaults to True
|
|
209
|
+
_path_to_item (tuple/list): This is a list of keys or values to
|
|
210
|
+
drill down to the model in received_data
|
|
211
|
+
when deserializing a response
|
|
212
|
+
_spec_property_naming (bool): True if the variable names in the input data
|
|
213
|
+
are serialized names, as specified in the OpenAPI document.
|
|
214
|
+
False if the variable names in the input data
|
|
215
|
+
are pythonic names, e.g. snake case (default)
|
|
216
|
+
_configuration (Configuration): the instance to use when
|
|
217
|
+
deserializing a file_type parameter.
|
|
218
|
+
If passed, type conversion is attempted
|
|
219
|
+
If omitted no type conversion is done.
|
|
220
|
+
_visited_composed_classes (tuple): This stores a tuple of
|
|
221
|
+
classes that we have traveled through so that
|
|
222
|
+
if we see that class again we will not use its
|
|
223
|
+
discriminator again.
|
|
224
|
+
When traveling through a discriminator, the
|
|
225
|
+
composed schema that is
|
|
226
|
+
is traveled through is added to this set.
|
|
227
|
+
For example if Animal has a discriminator
|
|
228
|
+
petType and we pass in "Dog", and the class Dog
|
|
229
|
+
allOf includes Animal, we move through Animal
|
|
230
|
+
once using the discriminator, and pick Dog.
|
|
231
|
+
Then in Dog, we will make an instance of the
|
|
232
|
+
Animal class but this time we won't travel
|
|
233
|
+
through its discriminator because we passed in
|
|
234
|
+
_visited_composed_classes = (Animal,)
|
|
235
|
+
"""
|
|
236
|
+
|
|
237
|
+
_check_type = kwargs.pop('_check_type', True)
|
|
238
|
+
_spec_property_naming = kwargs.pop('_spec_property_naming', False)
|
|
239
|
+
_path_to_item = kwargs.pop('_path_to_item', ())
|
|
240
|
+
_configuration = kwargs.pop('_configuration', None)
|
|
241
|
+
_visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
|
|
242
|
+
|
|
243
|
+
if args:
|
|
244
|
+
for arg in args:
|
|
245
|
+
if isinstance(arg, dict):
|
|
246
|
+
kwargs.update(arg)
|
|
247
|
+
else:
|
|
248
|
+
raise ApiTypeError(
|
|
249
|
+
"Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
|
|
250
|
+
args,
|
|
251
|
+
self.__class__.__name__,
|
|
252
|
+
),
|
|
253
|
+
path_to_item=_path_to_item,
|
|
254
|
+
valid_classes=(self.__class__,),
|
|
255
|
+
)
|
|
256
|
+
|
|
257
|
+
self._data_store = {}
|
|
258
|
+
self._check_type = _check_type
|
|
259
|
+
self._spec_property_naming = _spec_property_naming
|
|
260
|
+
self._path_to_item = _path_to_item
|
|
261
|
+
self._configuration = _configuration
|
|
262
|
+
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
|
|
263
|
+
|
|
264
|
+
self.data = data
|
|
265
|
+
self.meta = meta
|
|
266
|
+
for var_name, var_value in kwargs.items():
|
|
267
|
+
if var_name not in self.attribute_map and \
|
|
268
|
+
self._configuration is not None and \
|
|
269
|
+
self._configuration.discard_unknown_keys and \
|
|
270
|
+
self.additional_properties_type is None:
|
|
271
|
+
# discard variable.
|
|
272
|
+
continue
|
|
273
|
+
setattr(self, var_name, var_value)
|
|
274
|
+
if var_name in self.read_only_vars:
|
|
275
|
+
raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate "
|
|
276
|
+
f"class with read only attributes.")
|
|
@@ -60,7 +60,13 @@ class PagingOffsetLimitMetadata(ModelNormal):
|
|
|
60
60
|
validations = {
|
|
61
61
|
}
|
|
62
62
|
|
|
63
|
-
|
|
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
|
|
64
70
|
|
|
65
71
|
_nullable = True
|
|
66
72
|
|
criteo_api_retailmedia_preview/model/{grant_consent_model.py → recommended_categories_request_v1.py}
RENAMED
|
@@ -30,7 +30,7 @@ from criteo_api_retailmedia_preview.exceptions import ApiAttributeError
|
|
|
30
30
|
|
|
31
31
|
|
|
32
32
|
|
|
33
|
-
class
|
|
33
|
+
class RecommendedCategoriesRequestV1(ModelNormal):
|
|
34
34
|
"""NOTE: This class is auto generated by OpenAPI Generator.
|
|
35
35
|
Ref: https://openapi-generator.tech
|
|
36
36
|
|
|
@@ -58,6 +58,9 @@ class GrantConsentModel(ModelNormal):
|
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
validations = {
|
|
61
|
+
('sku_ids',): {
|
|
62
|
+
'min_items': 1,
|
|
63
|
+
},
|
|
61
64
|
}
|
|
62
65
|
|
|
63
66
|
@cached_property
|
|
@@ -81,9 +84,7 @@ class GrantConsentModel(ModelNormal):
|
|
|
81
84
|
and the value is attribute type.
|
|
82
85
|
"""
|
|
83
86
|
return {
|
|
84
|
-
'
|
|
85
|
-
'client_id': (str,), # noqa: E501
|
|
86
|
-
'callback_state': (str,), # noqa: E501
|
|
87
|
+
'sku_ids': ([str],), # noqa: E501
|
|
87
88
|
}
|
|
88
89
|
|
|
89
90
|
@cached_property
|
|
@@ -92,9 +93,7 @@ class GrantConsentModel(ModelNormal):
|
|
|
92
93
|
|
|
93
94
|
|
|
94
95
|
attribute_map = {
|
|
95
|
-
'
|
|
96
|
-
'client_id': 'clientId', # noqa: E501
|
|
97
|
-
'callback_state': 'callbackState', # noqa: E501
|
|
96
|
+
'sku_ids': 'skuIds', # noqa: E501
|
|
98
97
|
}
|
|
99
98
|
|
|
100
99
|
read_only_vars = {
|
|
@@ -104,12 +103,11 @@ class GrantConsentModel(ModelNormal):
|
|
|
104
103
|
|
|
105
104
|
@classmethod
|
|
106
105
|
@convert_js_args_to_python_args
|
|
107
|
-
def _from_openapi_data(cls,
|
|
108
|
-
"""
|
|
106
|
+
def _from_openapi_data(cls, sku_ids, *args, **kwargs): # noqa: E501
|
|
107
|
+
"""RecommendedCategoriesRequestV1 - a model defined in OpenAPI
|
|
109
108
|
|
|
110
109
|
Args:
|
|
111
|
-
|
|
112
|
-
client_id (str):
|
|
110
|
+
sku_ids ([str]): Sku id list.
|
|
113
111
|
|
|
114
112
|
Keyword Args:
|
|
115
113
|
_check_type (bool): if True, values for parameters in openapi_types
|
|
@@ -142,7 +140,6 @@ class GrantConsentModel(ModelNormal):
|
|
|
142
140
|
Animal class but this time we won't travel
|
|
143
141
|
through its discriminator because we passed in
|
|
144
142
|
_visited_composed_classes = (Animal,)
|
|
145
|
-
callback_state (str): [optional] # noqa: E501
|
|
146
143
|
"""
|
|
147
144
|
|
|
148
145
|
_check_type = kwargs.pop('_check_type', True)
|
|
@@ -174,8 +171,7 @@ class GrantConsentModel(ModelNormal):
|
|
|
174
171
|
self._configuration = _configuration
|
|
175
172
|
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
|
|
176
173
|
|
|
177
|
-
self.
|
|
178
|
-
self.client_id = client_id
|
|
174
|
+
self.sku_ids = sku_ids
|
|
179
175
|
for var_name, var_value in kwargs.items():
|
|
180
176
|
if var_name not in self.attribute_map and \
|
|
181
177
|
self._configuration is not None and \
|
|
@@ -196,12 +192,11 @@ class GrantConsentModel(ModelNormal):
|
|
|
196
192
|
])
|
|
197
193
|
|
|
198
194
|
@convert_js_args_to_python_args
|
|
199
|
-
def __init__(self,
|
|
200
|
-
"""
|
|
195
|
+
def __init__(self, sku_ids, *args, **kwargs): # noqa: E501
|
|
196
|
+
"""RecommendedCategoriesRequestV1 - a model defined in OpenAPI
|
|
201
197
|
|
|
202
198
|
Args:
|
|
203
|
-
|
|
204
|
-
client_id (str):
|
|
199
|
+
sku_ids ([str]): Sku id list.
|
|
205
200
|
|
|
206
201
|
Keyword Args:
|
|
207
202
|
_check_type (bool): if True, values for parameters in openapi_types
|
|
@@ -234,7 +229,6 @@ class GrantConsentModel(ModelNormal):
|
|
|
234
229
|
Animal class but this time we won't travel
|
|
235
230
|
through its discriminator because we passed in
|
|
236
231
|
_visited_composed_classes = (Animal,)
|
|
237
|
-
callback_state (str): [optional] # noqa: E501
|
|
238
232
|
"""
|
|
239
233
|
|
|
240
234
|
_check_type = kwargs.pop('_check_type', True)
|
|
@@ -264,8 +258,7 @@ class GrantConsentModel(ModelNormal):
|
|
|
264
258
|
self._configuration = _configuration
|
|
265
259
|
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
|
|
266
260
|
|
|
267
|
-
self.
|
|
268
|
-
self.client_id = client_id
|
|
261
|
+
self.sku_ids = sku_ids
|
|
269
262
|
for var_name, var_value in kwargs.items():
|
|
270
263
|
if var_name not in self.attribute_map and \
|
|
271
264
|
self._configuration is not None and \
|