asteroid-odyssey 1.3.2__py3-none-any.whl → 1.3.4__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 (54) hide show
  1. asteroid_odyssey/agents_v1_gen/models/agent_profile.py +3 -3
  2. asteroid_odyssey/agents_v2_gen/__init__.py +57 -43
  3. asteroid_odyssey/agents_v2_gen/api/__init__.py +1 -1
  4. asteroid_odyssey/agents_v2_gen/api/default_api.py +1199 -0
  5. asteroid_odyssey/agents_v2_gen/api_client.py +1 -1
  6. asteroid_odyssey/agents_v2_gen/configuration.py +4 -14
  7. asteroid_odyssey/agents_v2_gen/exceptions.py +1 -1
  8. asteroid_odyssey/agents_v2_gen/models/__init__.py +28 -21
  9. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_action_completed.py +4 -4
  10. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_action_failed.py +4 -4
  11. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_action_started.py +4 -4
  12. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_file_added.py +100 -0
  13. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_generic.py +4 -4
  14. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_status_changed.py +4 -4
  15. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_step_completed.py +4 -4
  16. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_step_started.py +4 -4
  17. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_terminal.py +4 -4
  18. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_transitioned_node.py +4 -4
  19. asteroid_odyssey/agents_v2_gen/models/activity_payload_union_user_message_received.py +4 -4
  20. asteroid_odyssey/agents_v2_gen/models/{execution_activity.py → agents_execution_activity.py} +8 -8
  21. asteroid_odyssey/agents_v2_gen/models/agents_execution_activity_action_completed_payload.py +87 -0
  22. asteroid_odyssey/agents_v2_gen/models/{execution_activity_action_completed_payload.py → agents_execution_activity_action_failed_payload.py} +5 -5
  23. asteroid_odyssey/agents_v2_gen/models/{execution_activity_action_failed_payload.py → agents_execution_activity_action_started_payload.py} +5 -5
  24. asteroid_odyssey/agents_v2_gen/models/agents_execution_activity_file_added_payload.py +104 -0
  25. asteroid_odyssey/agents_v2_gen/models/{execution_activity_action_started_payload.py → agents_execution_activity_generic_payload.py} +5 -5
  26. asteroid_odyssey/agents_v2_gen/models/{execution_activity_payload_union.py → agents_execution_activity_payload_union.py} +26 -12
  27. asteroid_odyssey/agents_v2_gen/models/{execution_activity_status_changed_payload.py → agents_execution_activity_status_changed_payload.py} +26 -20
  28. asteroid_odyssey/agents_v2_gen/models/{execution_activity_step_started_payload.py → agents_execution_activity_step_completed_payload.py} +5 -5
  29. asteroid_odyssey/agents_v2_gen/models/{execution_activity_step_completed_payload.py → agents_execution_activity_step_started_payload.py} +5 -5
  30. asteroid_odyssey/agents_v2_gen/models/{execution_activity_transitioned_node_payload.py → agents_execution_activity_transitioned_node_payload.py} +5 -5
  31. asteroid_odyssey/agents_v2_gen/models/{execution_activity_user_message_received_payload.py → agents_execution_activity_user_message_received_payload.py} +5 -5
  32. asteroid_odyssey/agents_v2_gen/models/{execution_awaiting_confirmation_payload.py → agents_execution_awaiting_confirmation_payload.py} +5 -5
  33. asteroid_odyssey/agents_v2_gen/models/agents_execution_cancel_reason.py +38 -0
  34. asteroid_odyssey/agents_v2_gen/models/agents_execution_cancelled_payload.py +88 -0
  35. asteroid_odyssey/agents_v2_gen/models/{execution_completed_payload.py → agents_execution_completed_payload.py} +5 -5
  36. asteroid_odyssey/agents_v2_gen/models/{execution_failed_payload.py → agents_execution_failed_payload.py} +5 -5
  37. asteroid_odyssey/agents_v2_gen/models/{execution_paused_payload.py → agents_execution_paused_payload.py} +5 -5
  38. asteroid_odyssey/agents_v2_gen/models/{execution_status.py → agents_execution_status.py} +4 -4
  39. asteroid_odyssey/agents_v2_gen/models/{execution_terminal_payload.py → agents_execution_terminal_payload.py} +5 -5
  40. asteroid_odyssey/agents_v2_gen/models/{execution_activity_generic_payload.py → agents_execution_user_messages_add_text_body.py} +5 -5
  41. asteroid_odyssey/agents_v2_gen/models/agents_files_file.py +108 -0
  42. asteroid_odyssey/agents_v2_gen/models/common_bad_request_error_body.py +96 -0
  43. asteroid_odyssey/agents_v2_gen/models/common_forbidden_error_body.py +96 -0
  44. asteroid_odyssey/agents_v2_gen/models/{error.py → common_not_found_error_body.py} +15 -8
  45. asteroid_odyssey/agents_v2_gen/models/{versions.py → version.py} +5 -6
  46. asteroid_odyssey/agents_v2_gen/rest.py +1 -1
  47. asteroid_odyssey/client.py +177 -6
  48. {asteroid_odyssey-1.3.2.dist-info → asteroid_odyssey-1.3.4.dist-info}/METADATA +2 -1
  49. asteroid_odyssey-1.3.4.dist-info/RECORD +84 -0
  50. asteroid_odyssey/agents_v2_gen/api/execution_api.py +0 -625
  51. asteroid_odyssey/agents_v2_gen/models/execution_user_messages_add_text_body.py +0 -87
  52. asteroid_odyssey-1.3.2.dist-info/RECORD +0 -77
  53. {asteroid_odyssey-1.3.2.dist-info → asteroid_odyssey-1.3.4.dist-info}/WHEEL +0 -0
  54. {asteroid_odyssey-1.3.2.dist-info → asteroid_odyssey-1.3.4.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,1199 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ Agent Service
5
+
6
+ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
7
+
8
+ The version of the OpenAPI document: v1
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """ # noqa: E501
13
+
14
+ import warnings
15
+ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
16
+ from typing import Any, Dict, List, Optional, Tuple, Union
17
+ from typing_extensions import Annotated
18
+
19
+ from pydantic import Field, StrictBytes, StrictInt, StrictStr, field_validator
20
+ from typing import List, Optional, Tuple, Union
21
+ from typing_extensions import Annotated
22
+ from asteroid_odyssey.agents_v2_gen.models.agents_execution_activity import AgentsExecutionActivity
23
+ from asteroid_odyssey.agents_v2_gen.models.agents_execution_user_messages_add_text_body import AgentsExecutionUserMessagesAddTextBody
24
+ from asteroid_odyssey.agents_v2_gen.models.agents_files_file import AgentsFilesFile
25
+
26
+ from asteroid_odyssey.agents_v2_gen.api_client import ApiClient, RequestSerialized
27
+ from asteroid_odyssey.agents_v2_gen.api_response import ApiResponse
28
+ from asteroid_odyssey.agents_v2_gen.rest import RESTResponseType
29
+
30
+
31
+ class DefaultApi:
32
+ """NOTE: This class is auto generated by OpenAPI Generator
33
+ Ref: https://openapi-generator.tech
34
+
35
+ Do not edit the class manually.
36
+ """
37
+
38
+ def __init__(self, api_client=None) -> None:
39
+ if api_client is None:
40
+ api_client = ApiClient.get_default()
41
+ self.api_client = api_client
42
+
43
+
44
+ @validate_call
45
+ def execution_activities_get(
46
+ self,
47
+ execution_id: Annotated[StrictStr, Field(description="The unique identifier of the execution")],
48
+ order: Annotated[Optional[StrictStr], Field(description="Sort order for activities by timestamp")] = None,
49
+ limit: Annotated[Optional[StrictInt], Field(description="Maximum number of activities to return")] = None,
50
+ _request_timeout: Union[
51
+ None,
52
+ Annotated[StrictFloat, Field(gt=0)],
53
+ Tuple[
54
+ Annotated[StrictFloat, Field(gt=0)],
55
+ Annotated[StrictFloat, Field(gt=0)]
56
+ ]
57
+ ] = None,
58
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
59
+ _content_type: Optional[StrictStr] = None,
60
+ _headers: Optional[Dict[StrictStr, Any]] = None,
61
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
62
+ ) -> List[AgentsExecutionActivity]:
63
+ """Retrieve execution activities
64
+
65
+ Get activities for an execution
66
+
67
+ :param execution_id: The unique identifier of the execution (required)
68
+ :type execution_id: str
69
+ :param order: Sort order for activities by timestamp
70
+ :type order: str
71
+ :param limit: Maximum number of activities to return
72
+ :type limit: int
73
+ :param _request_timeout: timeout setting for this request. If one
74
+ number provided, it will be total request
75
+ timeout. It can also be a pair (tuple) of
76
+ (connection, read) timeouts.
77
+ :type _request_timeout: int, tuple(int, int), optional
78
+ :param _request_auth: set to override the auth_settings for an a single
79
+ request; this effectively ignores the
80
+ authentication in the spec for a single request.
81
+ :type _request_auth: dict, optional
82
+ :param _content_type: force content-type for the request.
83
+ :type _content_type: str, Optional
84
+ :param _headers: set to override the headers for a single
85
+ request; this effectively ignores the headers
86
+ in the spec for a single request.
87
+ :type _headers: dict, optional
88
+ :param _host_index: set to override the host_index for a single
89
+ request; this effectively ignores the host_index
90
+ in the spec for a single request.
91
+ :type _host_index: int, optional
92
+ :return: Returns the result object.
93
+ """ # noqa: E501
94
+
95
+ _param = self._execution_activities_get_serialize(
96
+ execution_id=execution_id,
97
+ order=order,
98
+ limit=limit,
99
+ _request_auth=_request_auth,
100
+ _content_type=_content_type,
101
+ _headers=_headers,
102
+ _host_index=_host_index
103
+ )
104
+
105
+ _response_types_map: Dict[str, Optional[str]] = {
106
+ '200': "List[AgentsExecutionActivity]",
107
+ '400': "CommonBadRequestErrorBody",
108
+ '403': "CommonForbiddenErrorBody",
109
+ '404': "CommonNotFoundErrorBody",
110
+ }
111
+ response_data = self.api_client.call_api(
112
+ *_param,
113
+ _request_timeout=_request_timeout
114
+ )
115
+ response_data.read()
116
+ return self.api_client.response_deserialize(
117
+ response_data=response_data,
118
+ response_types_map=_response_types_map,
119
+ ).data
120
+
121
+
122
+ @validate_call
123
+ def execution_activities_get_with_http_info(
124
+ self,
125
+ execution_id: Annotated[StrictStr, Field(description="The unique identifier of the execution")],
126
+ order: Annotated[Optional[StrictStr], Field(description="Sort order for activities by timestamp")] = None,
127
+ limit: Annotated[Optional[StrictInt], Field(description="Maximum number of activities to return")] = None,
128
+ _request_timeout: Union[
129
+ None,
130
+ Annotated[StrictFloat, Field(gt=0)],
131
+ Tuple[
132
+ Annotated[StrictFloat, Field(gt=0)],
133
+ Annotated[StrictFloat, Field(gt=0)]
134
+ ]
135
+ ] = None,
136
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
137
+ _content_type: Optional[StrictStr] = None,
138
+ _headers: Optional[Dict[StrictStr, Any]] = None,
139
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
140
+ ) -> ApiResponse[List[AgentsExecutionActivity]]:
141
+ """Retrieve execution activities
142
+
143
+ Get activities for an execution
144
+
145
+ :param execution_id: The unique identifier of the execution (required)
146
+ :type execution_id: str
147
+ :param order: Sort order for activities by timestamp
148
+ :type order: str
149
+ :param limit: Maximum number of activities to return
150
+ :type limit: int
151
+ :param _request_timeout: timeout setting for this request. If one
152
+ number provided, it will be total request
153
+ timeout. It can also be a pair (tuple) of
154
+ (connection, read) timeouts.
155
+ :type _request_timeout: int, tuple(int, int), optional
156
+ :param _request_auth: set to override the auth_settings for an a single
157
+ request; this effectively ignores the
158
+ authentication in the spec for a single request.
159
+ :type _request_auth: dict, optional
160
+ :param _content_type: force content-type for the request.
161
+ :type _content_type: str, Optional
162
+ :param _headers: set to override the headers for a single
163
+ request; this effectively ignores the headers
164
+ in the spec for a single request.
165
+ :type _headers: dict, optional
166
+ :param _host_index: set to override the host_index for a single
167
+ request; this effectively ignores the host_index
168
+ in the spec for a single request.
169
+ :type _host_index: int, optional
170
+ :return: Returns the result object.
171
+ """ # noqa: E501
172
+
173
+ _param = self._execution_activities_get_serialize(
174
+ execution_id=execution_id,
175
+ order=order,
176
+ limit=limit,
177
+ _request_auth=_request_auth,
178
+ _content_type=_content_type,
179
+ _headers=_headers,
180
+ _host_index=_host_index
181
+ )
182
+
183
+ _response_types_map: Dict[str, Optional[str]] = {
184
+ '200': "List[AgentsExecutionActivity]",
185
+ '400': "CommonBadRequestErrorBody",
186
+ '403': "CommonForbiddenErrorBody",
187
+ '404': "CommonNotFoundErrorBody",
188
+ }
189
+ response_data = self.api_client.call_api(
190
+ *_param,
191
+ _request_timeout=_request_timeout
192
+ )
193
+ response_data.read()
194
+ return self.api_client.response_deserialize(
195
+ response_data=response_data,
196
+ response_types_map=_response_types_map,
197
+ )
198
+
199
+
200
+ @validate_call
201
+ def execution_activities_get_without_preload_content(
202
+ self,
203
+ execution_id: Annotated[StrictStr, Field(description="The unique identifier of the execution")],
204
+ order: Annotated[Optional[StrictStr], Field(description="Sort order for activities by timestamp")] = None,
205
+ limit: Annotated[Optional[StrictInt], Field(description="Maximum number of activities to return")] = None,
206
+ _request_timeout: Union[
207
+ None,
208
+ Annotated[StrictFloat, Field(gt=0)],
209
+ Tuple[
210
+ Annotated[StrictFloat, Field(gt=0)],
211
+ Annotated[StrictFloat, Field(gt=0)]
212
+ ]
213
+ ] = None,
214
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
215
+ _content_type: Optional[StrictStr] = None,
216
+ _headers: Optional[Dict[StrictStr, Any]] = None,
217
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
218
+ ) -> RESTResponseType:
219
+ """Retrieve execution activities
220
+
221
+ Get activities for an execution
222
+
223
+ :param execution_id: The unique identifier of the execution (required)
224
+ :type execution_id: str
225
+ :param order: Sort order for activities by timestamp
226
+ :type order: str
227
+ :param limit: Maximum number of activities to return
228
+ :type limit: int
229
+ :param _request_timeout: timeout setting for this request. If one
230
+ number provided, it will be total request
231
+ timeout. It can also be a pair (tuple) of
232
+ (connection, read) timeouts.
233
+ :type _request_timeout: int, tuple(int, int), optional
234
+ :param _request_auth: set to override the auth_settings for an a single
235
+ request; this effectively ignores the
236
+ authentication in the spec for a single request.
237
+ :type _request_auth: dict, optional
238
+ :param _content_type: force content-type for the request.
239
+ :type _content_type: str, Optional
240
+ :param _headers: set to override the headers for a single
241
+ request; this effectively ignores the headers
242
+ in the spec for a single request.
243
+ :type _headers: dict, optional
244
+ :param _host_index: set to override the host_index for a single
245
+ request; this effectively ignores the host_index
246
+ in the spec for a single request.
247
+ :type _host_index: int, optional
248
+ :return: Returns the result object.
249
+ """ # noqa: E501
250
+
251
+ _param = self._execution_activities_get_serialize(
252
+ execution_id=execution_id,
253
+ order=order,
254
+ limit=limit,
255
+ _request_auth=_request_auth,
256
+ _content_type=_content_type,
257
+ _headers=_headers,
258
+ _host_index=_host_index
259
+ )
260
+
261
+ _response_types_map: Dict[str, Optional[str]] = {
262
+ '200': "List[AgentsExecutionActivity]",
263
+ '400': "CommonBadRequestErrorBody",
264
+ '403': "CommonForbiddenErrorBody",
265
+ '404': "CommonNotFoundErrorBody",
266
+ }
267
+ response_data = self.api_client.call_api(
268
+ *_param,
269
+ _request_timeout=_request_timeout
270
+ )
271
+ return response_data.response
272
+
273
+
274
+ def _execution_activities_get_serialize(
275
+ self,
276
+ execution_id,
277
+ order,
278
+ limit,
279
+ _request_auth,
280
+ _content_type,
281
+ _headers,
282
+ _host_index,
283
+ ) -> RequestSerialized:
284
+
285
+ _host = None
286
+
287
+ _collection_formats: Dict[str, str] = {
288
+ }
289
+
290
+ _path_params: Dict[str, str] = {}
291
+ _query_params: List[Tuple[str, str]] = []
292
+ _header_params: Dict[str, Optional[str]] = _headers or {}
293
+ _form_params: List[Tuple[str, str]] = []
294
+ _files: Dict[
295
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
296
+ ] = {}
297
+ _body_params: Optional[bytes] = None
298
+
299
+ # process the path parameters
300
+ if execution_id is not None:
301
+ _path_params['executionId'] = execution_id
302
+ # process the query parameters
303
+ if order is not None:
304
+
305
+ _query_params.append(('order', order))
306
+
307
+ if limit is not None:
308
+
309
+ _query_params.append(('limit', limit))
310
+
311
+ # process the header parameters
312
+ # process the form parameters
313
+ # process the body parameter
314
+
315
+
316
+ # set the HTTP header `Accept`
317
+ if 'Accept' not in _header_params:
318
+ _header_params['Accept'] = self.api_client.select_header_accept(
319
+ [
320
+ 'application/json'
321
+ ]
322
+ )
323
+
324
+
325
+ # authentication setting
326
+ _auth_settings: List[str] = [
327
+ 'ApiKeyAuth'
328
+ ]
329
+
330
+ return self.api_client.param_serialize(
331
+ method='GET',
332
+ resource_path='/executions/{executionId}/activities',
333
+ path_params=_path_params,
334
+ query_params=_query_params,
335
+ header_params=_header_params,
336
+ body=_body_params,
337
+ post_params=_form_params,
338
+ files=_files,
339
+ auth_settings=_auth_settings,
340
+ collection_formats=_collection_formats,
341
+ _host=_host,
342
+ _request_auth=_request_auth
343
+ )
344
+
345
+
346
+
347
+
348
+ @validate_call
349
+ def execution_context_files_get(
350
+ self,
351
+ execution_id: StrictStr,
352
+ _request_timeout: Union[
353
+ None,
354
+ Annotated[StrictFloat, Field(gt=0)],
355
+ Tuple[
356
+ Annotated[StrictFloat, Field(gt=0)],
357
+ Annotated[StrictFloat, Field(gt=0)]
358
+ ]
359
+ ] = None,
360
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
361
+ _content_type: Optional[StrictStr] = None,
362
+ _headers: Optional[Dict[StrictStr, Any]] = None,
363
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
364
+ ) -> List[AgentsFilesFile]:
365
+ """execution_context_files_get
366
+
367
+
368
+ :param execution_id: (required)
369
+ :type execution_id: str
370
+ :param _request_timeout: timeout setting for this request. If one
371
+ number provided, it will be total request
372
+ timeout. It can also be a pair (tuple) of
373
+ (connection, read) timeouts.
374
+ :type _request_timeout: int, tuple(int, int), optional
375
+ :param _request_auth: set to override the auth_settings for an a single
376
+ request; this effectively ignores the
377
+ authentication in the spec for a single request.
378
+ :type _request_auth: dict, optional
379
+ :param _content_type: force content-type for the request.
380
+ :type _content_type: str, Optional
381
+ :param _headers: set to override the headers for a single
382
+ request; this effectively ignores the headers
383
+ in the spec for a single request.
384
+ :type _headers: dict, optional
385
+ :param _host_index: set to override the host_index for a single
386
+ request; this effectively ignores the host_index
387
+ in the spec for a single request.
388
+ :type _host_index: int, optional
389
+ :return: Returns the result object.
390
+ """ # noqa: E501
391
+
392
+ _param = self._execution_context_files_get_serialize(
393
+ execution_id=execution_id,
394
+ _request_auth=_request_auth,
395
+ _content_type=_content_type,
396
+ _headers=_headers,
397
+ _host_index=_host_index
398
+ )
399
+
400
+ _response_types_map: Dict[str, Optional[str]] = {
401
+ '200': "List[AgentsFilesFile]",
402
+ '404': "str",
403
+ }
404
+ response_data = self.api_client.call_api(
405
+ *_param,
406
+ _request_timeout=_request_timeout
407
+ )
408
+ response_data.read()
409
+ return self.api_client.response_deserialize(
410
+ response_data=response_data,
411
+ response_types_map=_response_types_map,
412
+ ).data
413
+
414
+
415
+ @validate_call
416
+ def execution_context_files_get_with_http_info(
417
+ self,
418
+ execution_id: StrictStr,
419
+ _request_timeout: Union[
420
+ None,
421
+ Annotated[StrictFloat, Field(gt=0)],
422
+ Tuple[
423
+ Annotated[StrictFloat, Field(gt=0)],
424
+ Annotated[StrictFloat, Field(gt=0)]
425
+ ]
426
+ ] = None,
427
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
428
+ _content_type: Optional[StrictStr] = None,
429
+ _headers: Optional[Dict[StrictStr, Any]] = None,
430
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
431
+ ) -> ApiResponse[List[AgentsFilesFile]]:
432
+ """execution_context_files_get
433
+
434
+
435
+ :param execution_id: (required)
436
+ :type execution_id: str
437
+ :param _request_timeout: timeout setting for this request. If one
438
+ number provided, it will be total request
439
+ timeout. It can also be a pair (tuple) of
440
+ (connection, read) timeouts.
441
+ :type _request_timeout: int, tuple(int, int), optional
442
+ :param _request_auth: set to override the auth_settings for an a single
443
+ request; this effectively ignores the
444
+ authentication in the spec for a single request.
445
+ :type _request_auth: dict, optional
446
+ :param _content_type: force content-type for the request.
447
+ :type _content_type: str, Optional
448
+ :param _headers: set to override the headers for a single
449
+ request; this effectively ignores the headers
450
+ in the spec for a single request.
451
+ :type _headers: dict, optional
452
+ :param _host_index: set to override the host_index for a single
453
+ request; this effectively ignores the host_index
454
+ in the spec for a single request.
455
+ :type _host_index: int, optional
456
+ :return: Returns the result object.
457
+ """ # noqa: E501
458
+
459
+ _param = self._execution_context_files_get_serialize(
460
+ execution_id=execution_id,
461
+ _request_auth=_request_auth,
462
+ _content_type=_content_type,
463
+ _headers=_headers,
464
+ _host_index=_host_index
465
+ )
466
+
467
+ _response_types_map: Dict[str, Optional[str]] = {
468
+ '200': "List[AgentsFilesFile]",
469
+ '404': "str",
470
+ }
471
+ response_data = self.api_client.call_api(
472
+ *_param,
473
+ _request_timeout=_request_timeout
474
+ )
475
+ response_data.read()
476
+ return self.api_client.response_deserialize(
477
+ response_data=response_data,
478
+ response_types_map=_response_types_map,
479
+ )
480
+
481
+
482
+ @validate_call
483
+ def execution_context_files_get_without_preload_content(
484
+ self,
485
+ execution_id: StrictStr,
486
+ _request_timeout: Union[
487
+ None,
488
+ Annotated[StrictFloat, Field(gt=0)],
489
+ Tuple[
490
+ Annotated[StrictFloat, Field(gt=0)],
491
+ Annotated[StrictFloat, Field(gt=0)]
492
+ ]
493
+ ] = None,
494
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
495
+ _content_type: Optional[StrictStr] = None,
496
+ _headers: Optional[Dict[StrictStr, Any]] = None,
497
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
498
+ ) -> RESTResponseType:
499
+ """execution_context_files_get
500
+
501
+
502
+ :param execution_id: (required)
503
+ :type execution_id: str
504
+ :param _request_timeout: timeout setting for this request. If one
505
+ number provided, it will be total request
506
+ timeout. It can also be a pair (tuple) of
507
+ (connection, read) timeouts.
508
+ :type _request_timeout: int, tuple(int, int), optional
509
+ :param _request_auth: set to override the auth_settings for an a single
510
+ request; this effectively ignores the
511
+ authentication in the spec for a single request.
512
+ :type _request_auth: dict, optional
513
+ :param _content_type: force content-type for the request.
514
+ :type _content_type: str, Optional
515
+ :param _headers: set to override the headers for a single
516
+ request; this effectively ignores the headers
517
+ in the spec for a single request.
518
+ :type _headers: dict, optional
519
+ :param _host_index: set to override the host_index for a single
520
+ request; this effectively ignores the host_index
521
+ in the spec for a single request.
522
+ :type _host_index: int, optional
523
+ :return: Returns the result object.
524
+ """ # noqa: E501
525
+
526
+ _param = self._execution_context_files_get_serialize(
527
+ execution_id=execution_id,
528
+ _request_auth=_request_auth,
529
+ _content_type=_content_type,
530
+ _headers=_headers,
531
+ _host_index=_host_index
532
+ )
533
+
534
+ _response_types_map: Dict[str, Optional[str]] = {
535
+ '200': "List[AgentsFilesFile]",
536
+ '404': "str",
537
+ }
538
+ response_data = self.api_client.call_api(
539
+ *_param,
540
+ _request_timeout=_request_timeout
541
+ )
542
+ return response_data.response
543
+
544
+
545
+ def _execution_context_files_get_serialize(
546
+ self,
547
+ execution_id,
548
+ _request_auth,
549
+ _content_type,
550
+ _headers,
551
+ _host_index,
552
+ ) -> RequestSerialized:
553
+
554
+ _host = None
555
+
556
+ _collection_formats: Dict[str, str] = {
557
+ }
558
+
559
+ _path_params: Dict[str, str] = {}
560
+ _query_params: List[Tuple[str, str]] = []
561
+ _header_params: Dict[str, Optional[str]] = _headers or {}
562
+ _form_params: List[Tuple[str, str]] = []
563
+ _files: Dict[
564
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
565
+ ] = {}
566
+ _body_params: Optional[bytes] = None
567
+
568
+ # process the path parameters
569
+ if execution_id is not None:
570
+ _path_params['executionId'] = execution_id
571
+ # process the query parameters
572
+ # process the header parameters
573
+ # process the form parameters
574
+ # process the body parameter
575
+
576
+
577
+ # set the HTTP header `Accept`
578
+ if 'Accept' not in _header_params:
579
+ _header_params['Accept'] = self.api_client.select_header_accept(
580
+ [
581
+ 'application/json',
582
+ 'text/plain'
583
+ ]
584
+ )
585
+
586
+
587
+ # authentication setting
588
+ _auth_settings: List[str] = [
589
+ 'ApiKeyAuth'
590
+ ]
591
+
592
+ return self.api_client.param_serialize(
593
+ method='GET',
594
+ resource_path='/executions/{executionId}/context-files',
595
+ path_params=_path_params,
596
+ query_params=_query_params,
597
+ header_params=_header_params,
598
+ body=_body_params,
599
+ post_params=_form_params,
600
+ files=_files,
601
+ auth_settings=_auth_settings,
602
+ collection_formats=_collection_formats,
603
+ _host=_host,
604
+ _request_auth=_request_auth
605
+ )
606
+
607
+
608
+
609
+
610
+ @validate_call
611
+ def execution_context_files_upload(
612
+ self,
613
+ execution_id: StrictStr,
614
+ files: List[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]],
615
+ _request_timeout: Union[
616
+ None,
617
+ Annotated[StrictFloat, Field(gt=0)],
618
+ Tuple[
619
+ Annotated[StrictFloat, Field(gt=0)],
620
+ Annotated[StrictFloat, Field(gt=0)]
621
+ ]
622
+ ] = None,
623
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
624
+ _content_type: Optional[StrictStr] = None,
625
+ _headers: Optional[Dict[StrictStr, Any]] = None,
626
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
627
+ ) -> str:
628
+ """execution_context_files_upload
629
+
630
+
631
+ :param execution_id: (required)
632
+ :type execution_id: str
633
+ :param files: (required)
634
+ :type files: List[bytearray]
635
+ :param _request_timeout: timeout setting for this request. If one
636
+ number provided, it will be total request
637
+ timeout. It can also be a pair (tuple) of
638
+ (connection, read) timeouts.
639
+ :type _request_timeout: int, tuple(int, int), optional
640
+ :param _request_auth: set to override the auth_settings for an a single
641
+ request; this effectively ignores the
642
+ authentication in the spec for a single request.
643
+ :type _request_auth: dict, optional
644
+ :param _content_type: force content-type for the request.
645
+ :type _content_type: str, Optional
646
+ :param _headers: set to override the headers for a single
647
+ request; this effectively ignores the headers
648
+ in the spec for a single request.
649
+ :type _headers: dict, optional
650
+ :param _host_index: set to override the host_index for a single
651
+ request; this effectively ignores the host_index
652
+ in the spec for a single request.
653
+ :type _host_index: int, optional
654
+ :return: Returns the result object.
655
+ """ # noqa: E501
656
+
657
+ _param = self._execution_context_files_upload_serialize(
658
+ execution_id=execution_id,
659
+ files=files,
660
+ _request_auth=_request_auth,
661
+ _content_type=_content_type,
662
+ _headers=_headers,
663
+ _host_index=_host_index
664
+ )
665
+
666
+ _response_types_map: Dict[str, Optional[str]] = {
667
+ '200': "str",
668
+ '400': "str",
669
+ '404': "str",
670
+ }
671
+ response_data = self.api_client.call_api(
672
+ *_param,
673
+ _request_timeout=_request_timeout
674
+ )
675
+ response_data.read()
676
+ return self.api_client.response_deserialize(
677
+ response_data=response_data,
678
+ response_types_map=_response_types_map,
679
+ ).data
680
+
681
+
682
+ @validate_call
683
+ def execution_context_files_upload_with_http_info(
684
+ self,
685
+ execution_id: StrictStr,
686
+ files: List[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]],
687
+ _request_timeout: Union[
688
+ None,
689
+ Annotated[StrictFloat, Field(gt=0)],
690
+ Tuple[
691
+ Annotated[StrictFloat, Field(gt=0)],
692
+ Annotated[StrictFloat, Field(gt=0)]
693
+ ]
694
+ ] = None,
695
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
696
+ _content_type: Optional[StrictStr] = None,
697
+ _headers: Optional[Dict[StrictStr, Any]] = None,
698
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
699
+ ) -> ApiResponse[str]:
700
+ """execution_context_files_upload
701
+
702
+
703
+ :param execution_id: (required)
704
+ :type execution_id: str
705
+ :param files: (required)
706
+ :type files: List[bytearray]
707
+ :param _request_timeout: timeout setting for this request. If one
708
+ number provided, it will be total request
709
+ timeout. It can also be a pair (tuple) of
710
+ (connection, read) timeouts.
711
+ :type _request_timeout: int, tuple(int, int), optional
712
+ :param _request_auth: set to override the auth_settings for an a single
713
+ request; this effectively ignores the
714
+ authentication in the spec for a single request.
715
+ :type _request_auth: dict, optional
716
+ :param _content_type: force content-type for the request.
717
+ :type _content_type: str, Optional
718
+ :param _headers: set to override the headers for a single
719
+ request; this effectively ignores the headers
720
+ in the spec for a single request.
721
+ :type _headers: dict, optional
722
+ :param _host_index: set to override the host_index for a single
723
+ request; this effectively ignores the host_index
724
+ in the spec for a single request.
725
+ :type _host_index: int, optional
726
+ :return: Returns the result object.
727
+ """ # noqa: E501
728
+
729
+ _param = self._execution_context_files_upload_serialize(
730
+ execution_id=execution_id,
731
+ files=files,
732
+ _request_auth=_request_auth,
733
+ _content_type=_content_type,
734
+ _headers=_headers,
735
+ _host_index=_host_index
736
+ )
737
+
738
+ _response_types_map: Dict[str, Optional[str]] = {
739
+ '200': "str",
740
+ '400': "str",
741
+ '404': "str",
742
+ }
743
+ response_data = self.api_client.call_api(
744
+ *_param,
745
+ _request_timeout=_request_timeout
746
+ )
747
+ response_data.read()
748
+ return self.api_client.response_deserialize(
749
+ response_data=response_data,
750
+ response_types_map=_response_types_map,
751
+ )
752
+
753
+
754
+ @validate_call
755
+ def execution_context_files_upload_without_preload_content(
756
+ self,
757
+ execution_id: StrictStr,
758
+ files: List[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]],
759
+ _request_timeout: Union[
760
+ None,
761
+ Annotated[StrictFloat, Field(gt=0)],
762
+ Tuple[
763
+ Annotated[StrictFloat, Field(gt=0)],
764
+ Annotated[StrictFloat, Field(gt=0)]
765
+ ]
766
+ ] = None,
767
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
768
+ _content_type: Optional[StrictStr] = None,
769
+ _headers: Optional[Dict[StrictStr, Any]] = None,
770
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
771
+ ) -> RESTResponseType:
772
+ """execution_context_files_upload
773
+
774
+
775
+ :param execution_id: (required)
776
+ :type execution_id: str
777
+ :param files: (required)
778
+ :type files: List[bytearray]
779
+ :param _request_timeout: timeout setting for this request. If one
780
+ number provided, it will be total request
781
+ timeout. It can also be a pair (tuple) of
782
+ (connection, read) timeouts.
783
+ :type _request_timeout: int, tuple(int, int), optional
784
+ :param _request_auth: set to override the auth_settings for an a single
785
+ request; this effectively ignores the
786
+ authentication in the spec for a single request.
787
+ :type _request_auth: dict, optional
788
+ :param _content_type: force content-type for the request.
789
+ :type _content_type: str, Optional
790
+ :param _headers: set to override the headers for a single
791
+ request; this effectively ignores the headers
792
+ in the spec for a single request.
793
+ :type _headers: dict, optional
794
+ :param _host_index: set to override the host_index for a single
795
+ request; this effectively ignores the host_index
796
+ in the spec for a single request.
797
+ :type _host_index: int, optional
798
+ :return: Returns the result object.
799
+ """ # noqa: E501
800
+
801
+ _param = self._execution_context_files_upload_serialize(
802
+ execution_id=execution_id,
803
+ files=files,
804
+ _request_auth=_request_auth,
805
+ _content_type=_content_type,
806
+ _headers=_headers,
807
+ _host_index=_host_index
808
+ )
809
+
810
+ _response_types_map: Dict[str, Optional[str]] = {
811
+ '200': "str",
812
+ '400': "str",
813
+ '404': "str",
814
+ }
815
+ response_data = self.api_client.call_api(
816
+ *_param,
817
+ _request_timeout=_request_timeout
818
+ )
819
+ return response_data.response
820
+
821
+
822
+ def _execution_context_files_upload_serialize(
823
+ self,
824
+ execution_id,
825
+ files,
826
+ _request_auth,
827
+ _content_type,
828
+ _headers,
829
+ _host_index,
830
+ ) -> RequestSerialized:
831
+
832
+ _host = None
833
+
834
+ _collection_formats: Dict[str, str] = {
835
+ 'files': 'multi',
836
+ }
837
+
838
+ _path_params: Dict[str, str] = {}
839
+ _query_params: List[Tuple[str, str]] = []
840
+ _header_params: Dict[str, Optional[str]] = _headers or {}
841
+ _form_params: List[Tuple[str, str]] = []
842
+ _files: Dict[
843
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
844
+ ] = {}
845
+ _body_params: Optional[bytes] = None
846
+
847
+ # process the path parameters
848
+ if execution_id is not None:
849
+ _path_params['executionId'] = execution_id
850
+ # process the query parameters
851
+ # process the header parameters
852
+ # process the form parameters
853
+ if files is not None:
854
+ _files['files'] = files
855
+ # process the body parameter
856
+
857
+
858
+ # set the HTTP header `Accept`
859
+ if 'Accept' not in _header_params:
860
+ _header_params['Accept'] = self.api_client.select_header_accept(
861
+ [
862
+ 'text/plain'
863
+ ]
864
+ )
865
+
866
+ # set the HTTP header `Content-Type`
867
+ if _content_type:
868
+ _header_params['Content-Type'] = _content_type
869
+ else:
870
+ _default_content_type = (
871
+ self.api_client.select_header_content_type(
872
+ [
873
+ 'multipart/form-data'
874
+ ]
875
+ )
876
+ )
877
+ if _default_content_type is not None:
878
+ _header_params['Content-Type'] = _default_content_type
879
+
880
+ # authentication setting
881
+ _auth_settings: List[str] = [
882
+ 'ApiKeyAuth'
883
+ ]
884
+
885
+ return self.api_client.param_serialize(
886
+ method='POST',
887
+ resource_path='/executions/{executionId}/context-files',
888
+ path_params=_path_params,
889
+ query_params=_query_params,
890
+ header_params=_header_params,
891
+ body=_body_params,
892
+ post_params=_form_params,
893
+ files=_files,
894
+ auth_settings=_auth_settings,
895
+ collection_formats=_collection_formats,
896
+ _host=_host,
897
+ _request_auth=_request_auth
898
+ )
899
+
900
+
901
+
902
+
903
+ @validate_call
904
+ def execution_user_messages_add(
905
+ self,
906
+ execution_id: Annotated[StrictStr, Field(description="The unique identifier of the execution")],
907
+ agents_execution_user_messages_add_text_body: Annotated[AgentsExecutionUserMessagesAddTextBody, Field(description="The message content to send")],
908
+ _request_timeout: Union[
909
+ None,
910
+ Annotated[StrictFloat, Field(gt=0)],
911
+ Tuple[
912
+ Annotated[StrictFloat, Field(gt=0)],
913
+ Annotated[StrictFloat, Field(gt=0)]
914
+ ]
915
+ ] = None,
916
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
917
+ _content_type: Optional[StrictStr] = None,
918
+ _headers: Optional[Dict[StrictStr, Any]] = None,
919
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
920
+ ) -> str:
921
+ """Send user message to execution
922
+
923
+ Add a user message to an execution
924
+
925
+ :param execution_id: The unique identifier of the execution (required)
926
+ :type execution_id: str
927
+ :param agents_execution_user_messages_add_text_body: The message content to send (required)
928
+ :type agents_execution_user_messages_add_text_body: AgentsExecutionUserMessagesAddTextBody
929
+ :param _request_timeout: timeout setting for this request. If one
930
+ number provided, it will be total request
931
+ timeout. It can also be a pair (tuple) of
932
+ (connection, read) timeouts.
933
+ :type _request_timeout: int, tuple(int, int), optional
934
+ :param _request_auth: set to override the auth_settings for an a single
935
+ request; this effectively ignores the
936
+ authentication in the spec for a single request.
937
+ :type _request_auth: dict, optional
938
+ :param _content_type: force content-type for the request.
939
+ :type _content_type: str, Optional
940
+ :param _headers: set to override the headers for a single
941
+ request; this effectively ignores the headers
942
+ in the spec for a single request.
943
+ :type _headers: dict, optional
944
+ :param _host_index: set to override the host_index for a single
945
+ request; this effectively ignores the host_index
946
+ in the spec for a single request.
947
+ :type _host_index: int, optional
948
+ :return: Returns the result object.
949
+ """ # noqa: E501
950
+
951
+ _param = self._execution_user_messages_add_serialize(
952
+ execution_id=execution_id,
953
+ agents_execution_user_messages_add_text_body=agents_execution_user_messages_add_text_body,
954
+ _request_auth=_request_auth,
955
+ _content_type=_content_type,
956
+ _headers=_headers,
957
+ _host_index=_host_index
958
+ )
959
+
960
+ _response_types_map: Dict[str, Optional[str]] = {
961
+ '201': "str",
962
+ '400': "CommonBadRequestErrorBody",
963
+ '403': "CommonForbiddenErrorBody",
964
+ '404': "CommonNotFoundErrorBody",
965
+ }
966
+ response_data = self.api_client.call_api(
967
+ *_param,
968
+ _request_timeout=_request_timeout
969
+ )
970
+ response_data.read()
971
+ return self.api_client.response_deserialize(
972
+ response_data=response_data,
973
+ response_types_map=_response_types_map,
974
+ ).data
975
+
976
+
977
+ @validate_call
978
+ def execution_user_messages_add_with_http_info(
979
+ self,
980
+ execution_id: Annotated[StrictStr, Field(description="The unique identifier of the execution")],
981
+ agents_execution_user_messages_add_text_body: Annotated[AgentsExecutionUserMessagesAddTextBody, Field(description="The message content to send")],
982
+ _request_timeout: Union[
983
+ None,
984
+ Annotated[StrictFloat, Field(gt=0)],
985
+ Tuple[
986
+ Annotated[StrictFloat, Field(gt=0)],
987
+ Annotated[StrictFloat, Field(gt=0)]
988
+ ]
989
+ ] = None,
990
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
991
+ _content_type: Optional[StrictStr] = None,
992
+ _headers: Optional[Dict[StrictStr, Any]] = None,
993
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
994
+ ) -> ApiResponse[str]:
995
+ """Send user message to execution
996
+
997
+ Add a user message to an execution
998
+
999
+ :param execution_id: The unique identifier of the execution (required)
1000
+ :type execution_id: str
1001
+ :param agents_execution_user_messages_add_text_body: The message content to send (required)
1002
+ :type agents_execution_user_messages_add_text_body: AgentsExecutionUserMessagesAddTextBody
1003
+ :param _request_timeout: timeout setting for this request. If one
1004
+ number provided, it will be total request
1005
+ timeout. It can also be a pair (tuple) of
1006
+ (connection, read) timeouts.
1007
+ :type _request_timeout: int, tuple(int, int), optional
1008
+ :param _request_auth: set to override the auth_settings for an a single
1009
+ request; this effectively ignores the
1010
+ authentication in the spec for a single request.
1011
+ :type _request_auth: dict, optional
1012
+ :param _content_type: force content-type for the request.
1013
+ :type _content_type: str, Optional
1014
+ :param _headers: set to override the headers for a single
1015
+ request; this effectively ignores the headers
1016
+ in the spec for a single request.
1017
+ :type _headers: dict, optional
1018
+ :param _host_index: set to override the host_index for a single
1019
+ request; this effectively ignores the host_index
1020
+ in the spec for a single request.
1021
+ :type _host_index: int, optional
1022
+ :return: Returns the result object.
1023
+ """ # noqa: E501
1024
+
1025
+ _param = self._execution_user_messages_add_serialize(
1026
+ execution_id=execution_id,
1027
+ agents_execution_user_messages_add_text_body=agents_execution_user_messages_add_text_body,
1028
+ _request_auth=_request_auth,
1029
+ _content_type=_content_type,
1030
+ _headers=_headers,
1031
+ _host_index=_host_index
1032
+ )
1033
+
1034
+ _response_types_map: Dict[str, Optional[str]] = {
1035
+ '201': "str",
1036
+ '400': "CommonBadRequestErrorBody",
1037
+ '403': "CommonForbiddenErrorBody",
1038
+ '404': "CommonNotFoundErrorBody",
1039
+ }
1040
+ response_data = self.api_client.call_api(
1041
+ *_param,
1042
+ _request_timeout=_request_timeout
1043
+ )
1044
+ response_data.read()
1045
+ return self.api_client.response_deserialize(
1046
+ response_data=response_data,
1047
+ response_types_map=_response_types_map,
1048
+ )
1049
+
1050
+
1051
+ @validate_call
1052
+ def execution_user_messages_add_without_preload_content(
1053
+ self,
1054
+ execution_id: Annotated[StrictStr, Field(description="The unique identifier of the execution")],
1055
+ agents_execution_user_messages_add_text_body: Annotated[AgentsExecutionUserMessagesAddTextBody, Field(description="The message content to send")],
1056
+ _request_timeout: Union[
1057
+ None,
1058
+ Annotated[StrictFloat, Field(gt=0)],
1059
+ Tuple[
1060
+ Annotated[StrictFloat, Field(gt=0)],
1061
+ Annotated[StrictFloat, Field(gt=0)]
1062
+ ]
1063
+ ] = None,
1064
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1065
+ _content_type: Optional[StrictStr] = None,
1066
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1067
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1068
+ ) -> RESTResponseType:
1069
+ """Send user message to execution
1070
+
1071
+ Add a user message to an execution
1072
+
1073
+ :param execution_id: The unique identifier of the execution (required)
1074
+ :type execution_id: str
1075
+ :param agents_execution_user_messages_add_text_body: The message content to send (required)
1076
+ :type agents_execution_user_messages_add_text_body: AgentsExecutionUserMessagesAddTextBody
1077
+ :param _request_timeout: timeout setting for this request. If one
1078
+ number provided, it will be total request
1079
+ timeout. It can also be a pair (tuple) of
1080
+ (connection, read) timeouts.
1081
+ :type _request_timeout: int, tuple(int, int), optional
1082
+ :param _request_auth: set to override the auth_settings for an a single
1083
+ request; this effectively ignores the
1084
+ authentication in the spec for a single request.
1085
+ :type _request_auth: dict, optional
1086
+ :param _content_type: force content-type for the request.
1087
+ :type _content_type: str, Optional
1088
+ :param _headers: set to override the headers for a single
1089
+ request; this effectively ignores the headers
1090
+ in the spec for a single request.
1091
+ :type _headers: dict, optional
1092
+ :param _host_index: set to override the host_index for a single
1093
+ request; this effectively ignores the host_index
1094
+ in the spec for a single request.
1095
+ :type _host_index: int, optional
1096
+ :return: Returns the result object.
1097
+ """ # noqa: E501
1098
+
1099
+ _param = self._execution_user_messages_add_serialize(
1100
+ execution_id=execution_id,
1101
+ agents_execution_user_messages_add_text_body=agents_execution_user_messages_add_text_body,
1102
+ _request_auth=_request_auth,
1103
+ _content_type=_content_type,
1104
+ _headers=_headers,
1105
+ _host_index=_host_index
1106
+ )
1107
+
1108
+ _response_types_map: Dict[str, Optional[str]] = {
1109
+ '201': "str",
1110
+ '400': "CommonBadRequestErrorBody",
1111
+ '403': "CommonForbiddenErrorBody",
1112
+ '404': "CommonNotFoundErrorBody",
1113
+ }
1114
+ response_data = self.api_client.call_api(
1115
+ *_param,
1116
+ _request_timeout=_request_timeout
1117
+ )
1118
+ return response_data.response
1119
+
1120
+
1121
+ def _execution_user_messages_add_serialize(
1122
+ self,
1123
+ execution_id,
1124
+ agents_execution_user_messages_add_text_body,
1125
+ _request_auth,
1126
+ _content_type,
1127
+ _headers,
1128
+ _host_index,
1129
+ ) -> RequestSerialized:
1130
+
1131
+ _host = None
1132
+
1133
+ _collection_formats: Dict[str, str] = {
1134
+ }
1135
+
1136
+ _path_params: Dict[str, str] = {}
1137
+ _query_params: List[Tuple[str, str]] = []
1138
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1139
+ _form_params: List[Tuple[str, str]] = []
1140
+ _files: Dict[
1141
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1142
+ ] = {}
1143
+ _body_params: Optional[bytes] = None
1144
+
1145
+ # process the path parameters
1146
+ if execution_id is not None:
1147
+ _path_params['executionId'] = execution_id
1148
+ # process the query parameters
1149
+ # process the header parameters
1150
+ # process the form parameters
1151
+ # process the body parameter
1152
+ if agents_execution_user_messages_add_text_body is not None:
1153
+ _body_params = agents_execution_user_messages_add_text_body
1154
+
1155
+
1156
+ # set the HTTP header `Accept`
1157
+ if 'Accept' not in _header_params:
1158
+ _header_params['Accept'] = self.api_client.select_header_accept(
1159
+ [
1160
+ 'text/plain',
1161
+ 'application/json'
1162
+ ]
1163
+ )
1164
+
1165
+ # set the HTTP header `Content-Type`
1166
+ if _content_type:
1167
+ _header_params['Content-Type'] = _content_type
1168
+ else:
1169
+ _default_content_type = (
1170
+ self.api_client.select_header_content_type(
1171
+ [
1172
+ 'application/json'
1173
+ ]
1174
+ )
1175
+ )
1176
+ if _default_content_type is not None:
1177
+ _header_params['Content-Type'] = _default_content_type
1178
+
1179
+ # authentication setting
1180
+ _auth_settings: List[str] = [
1181
+ 'ApiKeyAuth'
1182
+ ]
1183
+
1184
+ return self.api_client.param_serialize(
1185
+ method='POST',
1186
+ resource_path='/executions/{executionId}/user-messages',
1187
+ path_params=_path_params,
1188
+ query_params=_query_params,
1189
+ header_params=_header_params,
1190
+ body=_body_params,
1191
+ post_params=_form_params,
1192
+ files=_files,
1193
+ auth_settings=_auth_settings,
1194
+ collection_formats=_collection_formats,
1195
+ _host=_host,
1196
+ _request_auth=_request_auth
1197
+ )
1198
+
1199
+