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