ultracart-rest-sdk 4.1.49__py3-none-any.whl → 4.1.55__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.
- ultracart/__init__.py +1 -1
- ultracart/api/conversation_api.py +292 -0
- ultracart/api_client.py +1 -1
- ultracart/configuration.py +1 -1
- ultracart/model/conversation_pbx_agent.py +21 -4
- ultracart/model/conversation_pbx_call.py +370 -0
- ultracart/model/conversation_pbx_call_agent.py +296 -0
- ultracart/model/conversation_pbx_call_ai_cost.py +276 -0
- ultracart/model/conversation_pbx_call_ai_engagement.py +314 -0
- ultracart/model/conversation_pbx_call_ai_tool_call.py +296 -0
- ultracart/model/conversation_pbx_call_ai_whisper.py +276 -0
- ultracart/model/conversation_pbx_call_caller.py +280 -0
- ultracart/model/conversation_pbx_call_financial.py +288 -0
- ultracart/model/conversation_pbx_call_hold.py +276 -0
- ultracart/model/conversation_pbx_call_queue.py +284 -0
- ultracart/model/conversation_pbx_call_recording.py +294 -0
- ultracart/model/conversation_pbx_call_response.py +292 -0
- ultracart/model/conversation_pbx_call_routing.py +278 -0
- ultracart/model/conversation_pbx_call_search_request.py +324 -0
- ultracart/model/conversation_pbx_call_search_response.py +292 -0
- ultracart/model/conversation_pbx_call_timeline.py +284 -0
- ultracart/model/conversation_pbx_call_transcript.py +294 -0
- ultracart/model/conversation_pbx_call_transcript_segment.py +292 -0
- ultracart/model/conversation_pbx_call_transfer.py +280 -0
- ultracart/model/conversation_pbx_hardware_phone.py +21 -2
- ultracart/model/conversation_pbx_phone_number.py +4 -0
- ultracart/model/conversation_pbx_queue.py +4 -0
- ultracart/models/__init__.py +19 -0
- {ultracart_rest_sdk-4.1.49.dist-info → ultracart_rest_sdk-4.1.55.dist-info}/METADATA +1 -1
- {ultracart_rest_sdk-4.1.49.dist-info → ultracart_rest_sdk-4.1.55.dist-info}/RECORD +33 -14
- {ultracart_rest_sdk-4.1.49.dist-info → ultracart_rest_sdk-4.1.55.dist-info}/LICENSE +0 -0
- {ultracart_rest_sdk-4.1.49.dist-info → ultracart_rest_sdk-4.1.55.dist-info}/WHEEL +0 -0
- {ultracart_rest_sdk-4.1.49.dist-info → ultracart_rest_sdk-4.1.55.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,276 @@
|
|
|
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 ConversationPbxCallAiCost(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
|
+
'amount': (float,), # noqa: E501
|
|
86
|
+
'billed_minutes': (float,), # noqa: E501
|
|
87
|
+
'cost_per_minute': (float,), # noqa: E501
|
|
88
|
+
'currency': (str,), # noqa: E501
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
@cached_property
|
|
92
|
+
def discriminator():
|
|
93
|
+
return None
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
attribute_map = {
|
|
97
|
+
'amount': 'amount', # noqa: E501
|
|
98
|
+
'billed_minutes': 'billed_minutes', # noqa: E501
|
|
99
|
+
'cost_per_minute': 'cost_per_minute', # noqa: E501
|
|
100
|
+
'currency': 'currency', # noqa: E501
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
read_only_vars = {
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
_composed_schemas = {}
|
|
107
|
+
|
|
108
|
+
@classmethod
|
|
109
|
+
@convert_js_args_to_python_args
|
|
110
|
+
def _from_openapi_data(cls, *args, **kwargs): # noqa: E501
|
|
111
|
+
"""ConversationPbxCallAiCost - a model defined in OpenAPI
|
|
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
|
+
amount (float): Total cost amount in the specified currency. [optional] # noqa: E501
|
|
145
|
+
billed_minutes (float): Number of minutes billed for AI usage. [optional] # noqa: E501
|
|
146
|
+
cost_per_minute (float): Cost per minute for AI usage. [optional] # noqa: E501
|
|
147
|
+
currency (str): Currency code (always USD). [optional] # noqa: E501
|
|
148
|
+
"""
|
|
149
|
+
|
|
150
|
+
_check_type = kwargs.pop('_check_type', True)
|
|
151
|
+
_spec_property_naming = kwargs.pop('_spec_property_naming', True)
|
|
152
|
+
_path_to_item = kwargs.pop('_path_to_item', ())
|
|
153
|
+
_configuration = kwargs.pop('_configuration', None)
|
|
154
|
+
_visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
|
|
155
|
+
|
|
156
|
+
self = super(OpenApiModel, cls).__new__(cls)
|
|
157
|
+
|
|
158
|
+
if args:
|
|
159
|
+
for arg in args:
|
|
160
|
+
if isinstance(arg, dict):
|
|
161
|
+
kwargs.update(arg)
|
|
162
|
+
else:
|
|
163
|
+
raise ApiTypeError(
|
|
164
|
+
"Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
|
|
165
|
+
args,
|
|
166
|
+
self.__class__.__name__,
|
|
167
|
+
),
|
|
168
|
+
path_to_item=_path_to_item,
|
|
169
|
+
valid_classes=(self.__class__,),
|
|
170
|
+
)
|
|
171
|
+
|
|
172
|
+
self._data_store = {}
|
|
173
|
+
self._check_type = _check_type
|
|
174
|
+
self._spec_property_naming = _spec_property_naming
|
|
175
|
+
self._path_to_item = _path_to_item
|
|
176
|
+
self._configuration = _configuration
|
|
177
|
+
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
|
|
178
|
+
|
|
179
|
+
for var_name, var_value in kwargs.items():
|
|
180
|
+
if var_name not in self.attribute_map and \
|
|
181
|
+
self._configuration is not None and \
|
|
182
|
+
self._configuration.discard_unknown_keys and \
|
|
183
|
+
self.additional_properties_type is None:
|
|
184
|
+
# discard variable.
|
|
185
|
+
continue
|
|
186
|
+
setattr(self, var_name, var_value)
|
|
187
|
+
return self
|
|
188
|
+
|
|
189
|
+
required_properties = set([
|
|
190
|
+
'_data_store',
|
|
191
|
+
'_check_type',
|
|
192
|
+
'_spec_property_naming',
|
|
193
|
+
'_path_to_item',
|
|
194
|
+
'_configuration',
|
|
195
|
+
'_visited_composed_classes',
|
|
196
|
+
])
|
|
197
|
+
|
|
198
|
+
@convert_js_args_to_python_args
|
|
199
|
+
def __init__(self, *args, **kwargs): # noqa: E501
|
|
200
|
+
"""ConversationPbxCallAiCost - a model defined in OpenAPI
|
|
201
|
+
|
|
202
|
+
Keyword Args:
|
|
203
|
+
_check_type (bool): if True, values for parameters in openapi_types
|
|
204
|
+
will be type checked and a TypeError will be
|
|
205
|
+
raised if the wrong type is input.
|
|
206
|
+
Defaults to True
|
|
207
|
+
_path_to_item (tuple/list): This is a list of keys or values to
|
|
208
|
+
drill down to the model in received_data
|
|
209
|
+
when deserializing a response
|
|
210
|
+
_spec_property_naming (bool): True if the variable names in the input data
|
|
211
|
+
are serialized names, as specified in the OpenAPI document.
|
|
212
|
+
False if the variable names in the input data
|
|
213
|
+
are pythonic names, e.g. snake case (default)
|
|
214
|
+
_configuration (Configuration): the instance to use when
|
|
215
|
+
deserializing a file_type parameter.
|
|
216
|
+
If passed, type conversion is attempted
|
|
217
|
+
If omitted no type conversion is done.
|
|
218
|
+
_visited_composed_classes (tuple): This stores a tuple of
|
|
219
|
+
classes that we have traveled through so that
|
|
220
|
+
if we see that class again we will not use its
|
|
221
|
+
discriminator again.
|
|
222
|
+
When traveling through a discriminator, the
|
|
223
|
+
composed schema that is
|
|
224
|
+
is traveled through is added to this set.
|
|
225
|
+
For example if Animal has a discriminator
|
|
226
|
+
petType and we pass in "Dog", and the class Dog
|
|
227
|
+
allOf includes Animal, we move through Animal
|
|
228
|
+
once using the discriminator, and pick Dog.
|
|
229
|
+
Then in Dog, we will make an instance of the
|
|
230
|
+
Animal class but this time we won't travel
|
|
231
|
+
through its discriminator because we passed in
|
|
232
|
+
_visited_composed_classes = (Animal,)
|
|
233
|
+
amount (float): Total cost amount in the specified currency. [optional] # noqa: E501
|
|
234
|
+
billed_minutes (float): Number of minutes billed for AI usage. [optional] # noqa: E501
|
|
235
|
+
cost_per_minute (float): Cost per minute for AI usage. [optional] # noqa: E501
|
|
236
|
+
currency (str): Currency code (always USD). [optional] # noqa: E501
|
|
237
|
+
"""
|
|
238
|
+
|
|
239
|
+
_check_type = kwargs.pop('_check_type', True)
|
|
240
|
+
_spec_property_naming = kwargs.pop('_spec_property_naming', False)
|
|
241
|
+
_path_to_item = kwargs.pop('_path_to_item', ())
|
|
242
|
+
_configuration = kwargs.pop('_configuration', None)
|
|
243
|
+
_visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
|
|
244
|
+
|
|
245
|
+
if args:
|
|
246
|
+
for arg in args:
|
|
247
|
+
if isinstance(arg, dict):
|
|
248
|
+
kwargs.update(arg)
|
|
249
|
+
else:
|
|
250
|
+
raise ApiTypeError(
|
|
251
|
+
"Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
|
|
252
|
+
args,
|
|
253
|
+
self.__class__.__name__,
|
|
254
|
+
),
|
|
255
|
+
path_to_item=_path_to_item,
|
|
256
|
+
valid_classes=(self.__class__,),
|
|
257
|
+
)
|
|
258
|
+
|
|
259
|
+
self._data_store = {}
|
|
260
|
+
self._check_type = _check_type
|
|
261
|
+
self._spec_property_naming = _spec_property_naming
|
|
262
|
+
self._path_to_item = _path_to_item
|
|
263
|
+
self._configuration = _configuration
|
|
264
|
+
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
|
|
265
|
+
|
|
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.")
|
|
@@ -0,0 +1,314 @@
|
|
|
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.conversation_pbx_call_ai_cost import ConversationPbxCallAiCost
|
|
35
|
+
from ultracart.model.conversation_pbx_call_ai_tool_call import ConversationPbxCallAiToolCall
|
|
36
|
+
from ultracart.model.conversation_pbx_call_ai_whisper import ConversationPbxCallAiWhisper
|
|
37
|
+
globals()['ConversationPbxCallAiCost'] = ConversationPbxCallAiCost
|
|
38
|
+
globals()['ConversationPbxCallAiToolCall'] = ConversationPbxCallAiToolCall
|
|
39
|
+
globals()['ConversationPbxCallAiWhisper'] = ConversationPbxCallAiWhisper
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
class ConversationPbxCallAiEngagement(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
|
+
('engagement_type',): {
|
|
68
|
+
'AGENT': "ai_agent",
|
|
69
|
+
'COACH': "ai_coach",
|
|
70
|
+
},
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
validations = {
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
@cached_property
|
|
77
|
+
def additional_properties_type():
|
|
78
|
+
"""
|
|
79
|
+
This must be a method because a model may have properties that are
|
|
80
|
+
of type self, this must run after the class is loaded
|
|
81
|
+
"""
|
|
82
|
+
lazy_import()
|
|
83
|
+
return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501
|
|
84
|
+
|
|
85
|
+
_nullable = False
|
|
86
|
+
|
|
87
|
+
@cached_property
|
|
88
|
+
def openapi_types():
|
|
89
|
+
"""
|
|
90
|
+
This must be a method because a model may have properties that are
|
|
91
|
+
of type self, this must run after the class is loaded
|
|
92
|
+
|
|
93
|
+
Returns
|
|
94
|
+
openapi_types (dict): The key is attribute name
|
|
95
|
+
and the value is attribute type.
|
|
96
|
+
"""
|
|
97
|
+
lazy_import()
|
|
98
|
+
return {
|
|
99
|
+
'agent_name': (str,), # noqa: E501
|
|
100
|
+
'agent_uuid': (str,), # noqa: E501
|
|
101
|
+
'cost': (ConversationPbxCallAiCost,), # noqa: E501
|
|
102
|
+
'ended_at_dts': (str,), # noqa: E501
|
|
103
|
+
'engagement_type': (str,), # noqa: E501
|
|
104
|
+
'session_uuid': (str,), # noqa: E501
|
|
105
|
+
'started_at_dts': (str,), # noqa: E501
|
|
106
|
+
'status': (str,), # noqa: E501
|
|
107
|
+
'tool_calls': ([ConversationPbxCallAiToolCall],), # noqa: E501
|
|
108
|
+
'whispers': ([ConversationPbxCallAiWhisper],), # noqa: E501
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
@cached_property
|
|
112
|
+
def discriminator():
|
|
113
|
+
return None
|
|
114
|
+
|
|
115
|
+
|
|
116
|
+
attribute_map = {
|
|
117
|
+
'agent_name': 'agent_name', # noqa: E501
|
|
118
|
+
'agent_uuid': 'agent_uuid', # noqa: E501
|
|
119
|
+
'cost': 'cost', # noqa: E501
|
|
120
|
+
'ended_at_dts': 'ended_at_dts', # noqa: E501
|
|
121
|
+
'engagement_type': 'engagement_type', # noqa: E501
|
|
122
|
+
'session_uuid': 'session_uuid', # noqa: E501
|
|
123
|
+
'started_at_dts': 'started_at_dts', # noqa: E501
|
|
124
|
+
'status': 'status', # noqa: E501
|
|
125
|
+
'tool_calls': 'tool_calls', # noqa: E501
|
|
126
|
+
'whispers': 'whispers', # noqa: E501
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
read_only_vars = {
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
_composed_schemas = {}
|
|
133
|
+
|
|
134
|
+
@classmethod
|
|
135
|
+
@convert_js_args_to_python_args
|
|
136
|
+
def _from_openapi_data(cls, *args, **kwargs): # noqa: E501
|
|
137
|
+
"""ConversationPbxCallAiEngagement - a model defined in OpenAPI
|
|
138
|
+
|
|
139
|
+
Keyword Args:
|
|
140
|
+
_check_type (bool): if True, values for parameters in openapi_types
|
|
141
|
+
will be type checked and a TypeError will be
|
|
142
|
+
raised if the wrong type is input.
|
|
143
|
+
Defaults to True
|
|
144
|
+
_path_to_item (tuple/list): This is a list of keys or values to
|
|
145
|
+
drill down to the model in received_data
|
|
146
|
+
when deserializing a response
|
|
147
|
+
_spec_property_naming (bool): True if the variable names in the input data
|
|
148
|
+
are serialized names, as specified in the OpenAPI document.
|
|
149
|
+
False if the variable names in the input data
|
|
150
|
+
are pythonic names, e.g. snake case (default)
|
|
151
|
+
_configuration (Configuration): the instance to use when
|
|
152
|
+
deserializing a file_type parameter.
|
|
153
|
+
If passed, type conversion is attempted
|
|
154
|
+
If omitted no type conversion is done.
|
|
155
|
+
_visited_composed_classes (tuple): This stores a tuple of
|
|
156
|
+
classes that we have traveled through so that
|
|
157
|
+
if we see that class again we will not use its
|
|
158
|
+
discriminator again.
|
|
159
|
+
When traveling through a discriminator, the
|
|
160
|
+
composed schema that is
|
|
161
|
+
is traveled through is added to this set.
|
|
162
|
+
For example if Animal has a discriminator
|
|
163
|
+
petType and we pass in "Dog", and the class Dog
|
|
164
|
+
allOf includes Animal, we move through Animal
|
|
165
|
+
once using the discriminator, and pick Dog.
|
|
166
|
+
Then in Dog, we will make an instance of the
|
|
167
|
+
Animal class but this time we won't travel
|
|
168
|
+
through its discriminator because we passed in
|
|
169
|
+
_visited_composed_classes = (Animal,)
|
|
170
|
+
agent_name (str): Display name of the AI agent. [optional] # noqa: E501
|
|
171
|
+
agent_uuid (str): UUID of the AI agent configuration used. [optional] # noqa: E501
|
|
172
|
+
cost (ConversationPbxCallAiCost): [optional] # noqa: E501
|
|
173
|
+
ended_at_dts (str): Timestamp when the AI engagement ended. [optional] # noqa: E501
|
|
174
|
+
engagement_type (str): Type of AI engagement. [optional] # noqa: E501
|
|
175
|
+
session_uuid (str): Unique identifier for this AI engagement session. [optional] # noqa: E501
|
|
176
|
+
started_at_dts (str): Timestamp when the AI engagement started. [optional] # noqa: E501
|
|
177
|
+
status (str): Status of the AI engagement. [optional] # noqa: E501
|
|
178
|
+
tool_calls ([ConversationPbxCallAiToolCall]): List of tool calls made by the AI agent during this engagement. [optional] # noqa: E501
|
|
179
|
+
whispers ([ConversationPbxCallAiWhisper]): List of coaching whispers sent during this engagement. [optional] # noqa: E501
|
|
180
|
+
"""
|
|
181
|
+
|
|
182
|
+
_check_type = kwargs.pop('_check_type', True)
|
|
183
|
+
_spec_property_naming = kwargs.pop('_spec_property_naming', True)
|
|
184
|
+
_path_to_item = kwargs.pop('_path_to_item', ())
|
|
185
|
+
_configuration = kwargs.pop('_configuration', None)
|
|
186
|
+
_visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
|
|
187
|
+
|
|
188
|
+
self = super(OpenApiModel, cls).__new__(cls)
|
|
189
|
+
|
|
190
|
+
if args:
|
|
191
|
+
for arg in args:
|
|
192
|
+
if isinstance(arg, dict):
|
|
193
|
+
kwargs.update(arg)
|
|
194
|
+
else:
|
|
195
|
+
raise ApiTypeError(
|
|
196
|
+
"Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
|
|
197
|
+
args,
|
|
198
|
+
self.__class__.__name__,
|
|
199
|
+
),
|
|
200
|
+
path_to_item=_path_to_item,
|
|
201
|
+
valid_classes=(self.__class__,),
|
|
202
|
+
)
|
|
203
|
+
|
|
204
|
+
self._data_store = {}
|
|
205
|
+
self._check_type = _check_type
|
|
206
|
+
self._spec_property_naming = _spec_property_naming
|
|
207
|
+
self._path_to_item = _path_to_item
|
|
208
|
+
self._configuration = _configuration
|
|
209
|
+
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
|
|
210
|
+
|
|
211
|
+
for var_name, var_value in kwargs.items():
|
|
212
|
+
if var_name not in self.attribute_map and \
|
|
213
|
+
self._configuration is not None and \
|
|
214
|
+
self._configuration.discard_unknown_keys and \
|
|
215
|
+
self.additional_properties_type is None:
|
|
216
|
+
# discard variable.
|
|
217
|
+
continue
|
|
218
|
+
setattr(self, var_name, var_value)
|
|
219
|
+
return self
|
|
220
|
+
|
|
221
|
+
required_properties = set([
|
|
222
|
+
'_data_store',
|
|
223
|
+
'_check_type',
|
|
224
|
+
'_spec_property_naming',
|
|
225
|
+
'_path_to_item',
|
|
226
|
+
'_configuration',
|
|
227
|
+
'_visited_composed_classes',
|
|
228
|
+
])
|
|
229
|
+
|
|
230
|
+
@convert_js_args_to_python_args
|
|
231
|
+
def __init__(self, *args, **kwargs): # noqa: E501
|
|
232
|
+
"""ConversationPbxCallAiEngagement - a model defined in OpenAPI
|
|
233
|
+
|
|
234
|
+
Keyword Args:
|
|
235
|
+
_check_type (bool): if True, values for parameters in openapi_types
|
|
236
|
+
will be type checked and a TypeError will be
|
|
237
|
+
raised if the wrong type is input.
|
|
238
|
+
Defaults to True
|
|
239
|
+
_path_to_item (tuple/list): This is a list of keys or values to
|
|
240
|
+
drill down to the model in received_data
|
|
241
|
+
when deserializing a response
|
|
242
|
+
_spec_property_naming (bool): True if the variable names in the input data
|
|
243
|
+
are serialized names, as specified in the OpenAPI document.
|
|
244
|
+
False if the variable names in the input data
|
|
245
|
+
are pythonic names, e.g. snake case (default)
|
|
246
|
+
_configuration (Configuration): the instance to use when
|
|
247
|
+
deserializing a file_type parameter.
|
|
248
|
+
If passed, type conversion is attempted
|
|
249
|
+
If omitted no type conversion is done.
|
|
250
|
+
_visited_composed_classes (tuple): This stores a tuple of
|
|
251
|
+
classes that we have traveled through so that
|
|
252
|
+
if we see that class again we will not use its
|
|
253
|
+
discriminator again.
|
|
254
|
+
When traveling through a discriminator, the
|
|
255
|
+
composed schema that is
|
|
256
|
+
is traveled through is added to this set.
|
|
257
|
+
For example if Animal has a discriminator
|
|
258
|
+
petType and we pass in "Dog", and the class Dog
|
|
259
|
+
allOf includes Animal, we move through Animal
|
|
260
|
+
once using the discriminator, and pick Dog.
|
|
261
|
+
Then in Dog, we will make an instance of the
|
|
262
|
+
Animal class but this time we won't travel
|
|
263
|
+
through its discriminator because we passed in
|
|
264
|
+
_visited_composed_classes = (Animal,)
|
|
265
|
+
agent_name (str): Display name of the AI agent. [optional] # noqa: E501
|
|
266
|
+
agent_uuid (str): UUID of the AI agent configuration used. [optional] # noqa: E501
|
|
267
|
+
cost (ConversationPbxCallAiCost): [optional] # noqa: E501
|
|
268
|
+
ended_at_dts (str): Timestamp when the AI engagement ended. [optional] # noqa: E501
|
|
269
|
+
engagement_type (str): Type of AI engagement. [optional] # noqa: E501
|
|
270
|
+
session_uuid (str): Unique identifier for this AI engagement session. [optional] # noqa: E501
|
|
271
|
+
started_at_dts (str): Timestamp when the AI engagement started. [optional] # noqa: E501
|
|
272
|
+
status (str): Status of the AI engagement. [optional] # noqa: E501
|
|
273
|
+
tool_calls ([ConversationPbxCallAiToolCall]): List of tool calls made by the AI agent during this engagement. [optional] # noqa: E501
|
|
274
|
+
whispers ([ConversationPbxCallAiWhisper]): List of coaching whispers sent during this engagement. [optional] # noqa: E501
|
|
275
|
+
"""
|
|
276
|
+
|
|
277
|
+
_check_type = kwargs.pop('_check_type', True)
|
|
278
|
+
_spec_property_naming = kwargs.pop('_spec_property_naming', False)
|
|
279
|
+
_path_to_item = kwargs.pop('_path_to_item', ())
|
|
280
|
+
_configuration = kwargs.pop('_configuration', None)
|
|
281
|
+
_visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
|
|
282
|
+
|
|
283
|
+
if args:
|
|
284
|
+
for arg in args:
|
|
285
|
+
if isinstance(arg, dict):
|
|
286
|
+
kwargs.update(arg)
|
|
287
|
+
else:
|
|
288
|
+
raise ApiTypeError(
|
|
289
|
+
"Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
|
|
290
|
+
args,
|
|
291
|
+
self.__class__.__name__,
|
|
292
|
+
),
|
|
293
|
+
path_to_item=_path_to_item,
|
|
294
|
+
valid_classes=(self.__class__,),
|
|
295
|
+
)
|
|
296
|
+
|
|
297
|
+
self._data_store = {}
|
|
298
|
+
self._check_type = _check_type
|
|
299
|
+
self._spec_property_naming = _spec_property_naming
|
|
300
|
+
self._path_to_item = _path_to_item
|
|
301
|
+
self._configuration = _configuration
|
|
302
|
+
self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
|
|
303
|
+
|
|
304
|
+
for var_name, var_value in kwargs.items():
|
|
305
|
+
if var_name not in self.attribute_map and \
|
|
306
|
+
self._configuration is not None and \
|
|
307
|
+
self._configuration.discard_unknown_keys and \
|
|
308
|
+
self.additional_properties_type is None:
|
|
309
|
+
# discard variable.
|
|
310
|
+
continue
|
|
311
|
+
setattr(self, var_name, var_value)
|
|
312
|
+
if var_name in self.read_only_vars:
|
|
313
|
+
raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate "
|
|
314
|
+
f"class with read only attributes.")
|