vellum-ai 1.1.1__py3-none-any.whl → 1.1.3__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 (85) hide show
  1. vellum/__init__.py +16 -0
  2. vellum/client/README.md +55 -0
  3. vellum/client/__init__.py +66 -507
  4. vellum/client/core/client_wrapper.py +2 -2
  5. vellum/client/core/pydantic_utilities.py +10 -3
  6. vellum/client/raw_client.py +844 -0
  7. vellum/client/reference.md +692 -19
  8. vellum/client/resources/ad_hoc/client.py +23 -180
  9. vellum/client/resources/ad_hoc/raw_client.py +276 -0
  10. vellum/client/resources/container_images/client.py +10 -36
  11. vellum/client/resources/deployments/client.py +16 -62
  12. vellum/client/resources/document_indexes/client.py +16 -72
  13. vellum/client/resources/documents/client.py +8 -30
  14. vellum/client/resources/folder_entities/client.py +4 -8
  15. vellum/client/resources/metric_definitions/client.py +4 -14
  16. vellum/client/resources/ml_models/client.py +2 -8
  17. vellum/client/resources/organizations/client.py +2 -6
  18. vellum/client/resources/prompts/client.py +2 -10
  19. vellum/client/resources/sandboxes/client.py +4 -20
  20. vellum/client/resources/test_suite_runs/client.py +4 -18
  21. vellum/client/resources/test_suites/client.py +11 -86
  22. vellum/client/resources/test_suites/raw_client.py +136 -0
  23. vellum/client/resources/workflow_deployments/client.py +20 -78
  24. vellum/client/resources/workflow_executions/client.py +2 -6
  25. vellum/client/resources/workflow_sandboxes/client.py +2 -10
  26. vellum/client/resources/workflows/client.py +7 -6
  27. vellum/client/resources/workflows/raw_client.py +58 -47
  28. vellum/client/resources/workspace_secrets/client.py +4 -20
  29. vellum/client/resources/workspaces/client.py +2 -6
  30. vellum/client/types/__init__.py +16 -0
  31. vellum/client/types/array_chat_message_content_item.py +4 -2
  32. vellum/client/types/array_chat_message_content_item_request.py +4 -2
  33. vellum/client/types/chat_message_content.py +4 -2
  34. vellum/client/types/chat_message_content_request.py +4 -2
  35. vellum/client/types/node_execution_span.py +2 -0
  36. vellum/client/types/prompt_block.py +4 -2
  37. vellum/client/types/vellum_value.py +4 -2
  38. vellum/client/types/vellum_value_request.py +4 -2
  39. vellum/client/types/vellum_variable_type.py +2 -1
  40. vellum/client/types/vellum_video.py +24 -0
  41. vellum/client/types/vellum_video_request.py +24 -0
  42. vellum/client/types/video_chat_message_content.py +25 -0
  43. vellum/client/types/video_chat_message_content_request.py +25 -0
  44. vellum/client/types/video_prompt_block.py +29 -0
  45. vellum/client/types/video_vellum_value.py +25 -0
  46. vellum/client/types/video_vellum_value_request.py +25 -0
  47. vellum/client/types/workflow_execution_span.py +2 -0
  48. vellum/client/types/workflow_execution_usage_calculation_fulfilled_body.py +22 -0
  49. vellum/prompts/blocks/compilation.py +22 -10
  50. vellum/types/vellum_video.py +3 -0
  51. vellum/types/vellum_video_request.py +3 -0
  52. vellum/types/video_chat_message_content.py +3 -0
  53. vellum/types/video_chat_message_content_request.py +3 -0
  54. vellum/types/video_prompt_block.py +3 -0
  55. vellum/types/video_vellum_value.py +3 -0
  56. vellum/types/video_vellum_value_request.py +3 -0
  57. vellum/types/workflow_execution_usage_calculation_fulfilled_body.py +3 -0
  58. vellum/workflows/events/workflow.py +11 -0
  59. vellum/workflows/graph/graph.py +103 -1
  60. vellum/workflows/graph/tests/test_graph.py +99 -0
  61. vellum/workflows/nodes/bases/base.py +9 -1
  62. vellum/workflows/nodes/displayable/bases/utils.py +4 -2
  63. vellum/workflows/nodes/displayable/tool_calling_node/node.py +19 -18
  64. vellum/workflows/nodes/displayable/tool_calling_node/tests/test_node.py +17 -7
  65. vellum/workflows/nodes/displayable/tool_calling_node/tests/test_utils.py +7 -7
  66. vellum/workflows/nodes/displayable/tool_calling_node/utils.py +47 -80
  67. vellum/workflows/references/environment_variable.py +10 -0
  68. vellum/workflows/runner/runner.py +18 -2
  69. vellum/workflows/state/context.py +101 -12
  70. vellum/workflows/types/definition.py +11 -1
  71. vellum/workflows/types/tests/test_definition.py +19 -0
  72. vellum/workflows/utils/vellum_variables.py +9 -5
  73. vellum/workflows/workflows/base.py +12 -5
  74. {vellum_ai-1.1.1.dist-info → vellum_ai-1.1.3.dist-info}/METADATA +1 -1
  75. {vellum_ai-1.1.1.dist-info → vellum_ai-1.1.3.dist-info}/RECORD +85 -69
  76. vellum_ee/workflows/display/nodes/vellum/code_execution_node.py +1 -1
  77. vellum_ee/workflows/display/nodes/vellum/tests/test_code_execution_node.py +55 -1
  78. vellum_ee/workflows/display/nodes/vellum/tests/test_tool_calling_node.py +15 -52
  79. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_tool_calling_node_mcp_serialization.py +15 -49
  80. vellum_ee/workflows/display/types.py +14 -1
  81. vellum_ee/workflows/display/utils/expressions.py +13 -4
  82. vellum_ee/workflows/display/workflows/base_workflow_display.py +6 -19
  83. {vellum_ai-1.1.1.dist-info → vellum_ai-1.1.3.dist-info}/LICENSE +0 -0
  84. {vellum_ai-1.1.1.dist-info → vellum_ai-1.1.3.dist-info}/WHEEL +0 -0
  85. {vellum_ai-1.1.1.dist-info → vellum_ai-1.1.3.dist-info}/entry_points.txt +0 -0
@@ -120,10 +120,7 @@ class TestSuiteRunsClient:
120
120
  id="id",
121
121
  )
122
122
  """
123
- response = self._raw_client.retrieve(
124
- id,
125
- request_options=request_options,
126
- )
123
+ response = self._raw_client.retrieve(id, request_options=request_options)
127
124
  return response.data
128
125
 
129
126
  def list_executions(
@@ -174,11 +171,7 @@ class TestSuiteRunsClient:
174
171
  )
175
172
  """
176
173
  response = self._raw_client.list_executions(
177
- id,
178
- expand=expand,
179
- limit=limit,
180
- offset=offset,
181
- request_options=request_options,
174
+ id, expand=expand, limit=limit, offset=offset, request_options=request_options
182
175
  )
183
176
  return response.data
184
177
 
@@ -301,10 +294,7 @@ class AsyncTestSuiteRunsClient:
301
294
 
302
295
  asyncio.run(main())
303
296
  """
304
- response = await self._raw_client.retrieve(
305
- id,
306
- request_options=request_options,
307
- )
297
+ response = await self._raw_client.retrieve(id, request_options=request_options)
308
298
  return response.data
309
299
 
310
300
  async def list_executions(
@@ -363,10 +353,6 @@ class AsyncTestSuiteRunsClient:
363
353
  asyncio.run(main())
364
354
  """
365
355
  response = await self._raw_client.list_executions(
366
- id,
367
- expand=expand,
368
- limit=limit,
369
- offset=offset,
370
- request_options=request_options,
356
+ id, expand=expand, limit=limit, offset=offset, request_options=request_options
371
357
  )
372
358
  return response.data
@@ -9,12 +9,6 @@ from ...types.named_test_case_variable_value_request import NamedTestCaseVariabl
9
9
  from ...types.test_suite_test_case import TestSuiteTestCase
10
10
  from ...types.test_suite_test_case_bulk_operation_request import TestSuiteTestCaseBulkOperationRequest
11
11
  from ...types.test_suite_test_case_bulk_result import TestSuiteTestCaseBulkResult
12
- from ...core.jsonable_encoder import jsonable_encoder
13
- from ...core.serialization import convert_and_respect_annotation_metadata
14
- from ...core.pydantic_utilities import parse_obj_as
15
- import json
16
- from json.decoder import JSONDecodeError
17
- from ...core.api_error import ApiError
18
12
  from ...core.client_wrapper import AsyncClientWrapper
19
13
  from .raw_client import AsyncRawTestSuitesClient
20
14
 
@@ -84,10 +78,7 @@ class TestSuitesClient:
84
78
  )
85
79
  """
86
80
  response = self._raw_client.list_test_suite_test_cases(
87
- id,
88
- limit=limit,
89
- offset=offset,
90
- request_options=request_options,
81
+ id, limit=limit, offset=offset, request_options=request_options
91
82
  )
92
83
  return response.data
93
84
 
@@ -266,37 +257,8 @@ class TestSuitesClient:
266
257
  for chunk in response:
267
258
  yield chunk
268
259
  """
269
- with self._raw_client._client_wrapper.httpx_client.stream(
270
- f"v1/test-suites/{jsonable_encoder(id)}/test-cases-bulk",
271
- base_url=self._raw_client._client_wrapper.get_environment().default,
272
- method="POST",
273
- json=convert_and_respect_annotation_metadata(
274
- object_=request, annotation=typing.Sequence[TestSuiteTestCaseBulkOperationRequest], direction="write"
275
- ),
276
- request_options=request_options,
277
- omit=OMIT,
278
- ) as _response:
279
- try:
280
- if 200 <= _response.status_code < 300:
281
- for _text in _response.iter_lines():
282
- try:
283
- if len(_text) == 0:
284
- continue
285
- yield typing.cast(
286
- typing.List[TestSuiteTestCaseBulkResult],
287
- parse_obj_as(
288
- type_=typing.List[TestSuiteTestCaseBulkResult], # type: ignore
289
- object_=json.loads(_text),
290
- ),
291
- )
292
- except Exception:
293
- pass
294
- return
295
- _response.read()
296
- _response_json = _response.json()
297
- except JSONDecodeError:
298
- raise ApiError(status_code=_response.status_code, body=_response.text)
299
- raise ApiError(status_code=_response.status_code, body=_response_json)
260
+ with self._raw_client.test_suite_test_cases_bulk(id, request=request, request_options=request_options) as r:
261
+ yield from r.data
300
262
 
301
263
  def delete_test_suite_test_case(
302
264
  self, id: str, test_case_id: str, *, request_options: typing.Optional[RequestOptions] = None
@@ -332,11 +294,7 @@ class TestSuitesClient:
332
294
  test_case_id="test_case_id",
333
295
  )
334
296
  """
335
- response = self._raw_client.delete_test_suite_test_case(
336
- id,
337
- test_case_id,
338
- request_options=request_options,
339
- )
297
+ response = self._raw_client.delete_test_suite_test_case(id, test_case_id, request_options=request_options)
340
298
  return response.data
341
299
 
342
300
 
@@ -406,10 +364,7 @@ class AsyncTestSuitesClient:
406
364
  asyncio.run(main())
407
365
  """
408
366
  response = await self._raw_client.list_test_suite_test_cases(
409
- id,
410
- limit=limit,
411
- offset=offset,
412
- request_options=request_options,
367
+ id, limit=limit, offset=offset, request_options=request_options
413
368
  )
414
369
  return response.data
415
370
 
@@ -604,37 +559,11 @@ class AsyncTestSuitesClient:
604
559
 
605
560
  asyncio.run(main())
606
561
  """
607
- async with self._raw_client._client_wrapper.httpx_client.stream(
608
- f"v1/test-suites/{jsonable_encoder(id)}/test-cases-bulk",
609
- base_url=self._raw_client._client_wrapper.get_environment().default,
610
- method="POST",
611
- json=convert_and_respect_annotation_metadata(
612
- object_=request, annotation=typing.Sequence[TestSuiteTestCaseBulkOperationRequest], direction="write"
613
- ),
614
- request_options=request_options,
615
- omit=OMIT,
616
- ) as _response:
617
- try:
618
- if 200 <= _response.status_code < 300:
619
- async for _text in _response.aiter_lines():
620
- try:
621
- if len(_text) == 0:
622
- continue
623
- yield typing.cast(
624
- typing.List[TestSuiteTestCaseBulkResult],
625
- parse_obj_as(
626
- type_=typing.List[TestSuiteTestCaseBulkResult], # type: ignore
627
- object_=json.loads(_text),
628
- ),
629
- )
630
- except Exception:
631
- pass
632
- return
633
- await _response.aread()
634
- _response_json = _response.json()
635
- except JSONDecodeError:
636
- raise ApiError(status_code=_response.status_code, body=_response.text)
637
- raise ApiError(status_code=_response.status_code, body=_response_json)
562
+ async with self._raw_client.test_suite_test_cases_bulk(
563
+ id, request=request, request_options=request_options
564
+ ) as r:
565
+ async for data in r.data:
566
+ yield data
638
567
 
639
568
  async def delete_test_suite_test_case(
640
569
  self, id: str, test_case_id: str, *, request_options: typing.Optional[RequestOptions] = None
@@ -678,9 +607,5 @@ class AsyncTestSuitesClient:
678
607
 
679
608
  asyncio.run(main())
680
609
  """
681
- response = await self._raw_client.delete_test_suite_test_case(
682
- id,
683
- test_case_id,
684
- request_options=request_options,
685
- )
610
+ response = await self._raw_client.delete_test_suite_test_case(id, test_case_id, request_options=request_options)
686
611
  return response.data
@@ -12,6 +12,10 @@ from ...core.api_error import ApiError
12
12
  from ...types.named_test_case_variable_value_request import NamedTestCaseVariableValueRequest
13
13
  from ...types.test_suite_test_case import TestSuiteTestCase
14
14
  from ...core.serialization import convert_and_respect_annotation_metadata
15
+ from ...types.test_suite_test_case_bulk_operation_request import TestSuiteTestCaseBulkOperationRequest
16
+ from ...types.test_suite_test_case_bulk_result import TestSuiteTestCaseBulkResult
17
+ import json
18
+ import contextlib
15
19
  from ...core.client_wrapper import AsyncClientWrapper
16
20
  from ...core.http_response import AsyncHttpResponse
17
21
 
@@ -163,6 +167,72 @@ class RawTestSuitesClient:
163
167
  raise ApiError(status_code=_response.status_code, body=_response.text)
164
168
  raise ApiError(status_code=_response.status_code, body=_response_json)
165
169
 
170
+ @contextlib.contextmanager
171
+ def test_suite_test_cases_bulk(
172
+ self,
173
+ id: str,
174
+ *,
175
+ request: typing.Sequence[TestSuiteTestCaseBulkOperationRequest],
176
+ request_options: typing.Optional[RequestOptions] = None,
177
+ ) -> typing.Iterator[HttpResponse[typing.Iterator[typing.List[TestSuiteTestCaseBulkResult]]]]:
178
+ """
179
+ Created, replace, and delete Test Cases within the specified Test Suite in bulk
180
+
181
+ Parameters
182
+ ----------
183
+ id : str
184
+ Either the Test Suites' ID or its unique name
185
+
186
+ request : typing.Sequence[TestSuiteTestCaseBulkOperationRequest]
187
+
188
+ request_options : typing.Optional[RequestOptions]
189
+ Request-specific configuration.
190
+
191
+ Yields
192
+ ------
193
+ typing.Iterator[HttpResponse[typing.Iterator[typing.List[TestSuiteTestCaseBulkResult]]]]
194
+
195
+ """
196
+ with self._client_wrapper.httpx_client.stream(
197
+ f"v1/test-suites/{jsonable_encoder(id)}/test-cases-bulk",
198
+ base_url=self._client_wrapper.get_environment().default,
199
+ method="POST",
200
+ json=convert_and_respect_annotation_metadata(
201
+ object_=request, annotation=typing.Sequence[TestSuiteTestCaseBulkOperationRequest], direction="write"
202
+ ),
203
+ request_options=request_options,
204
+ omit=OMIT,
205
+ ) as _response:
206
+
207
+ def stream() -> HttpResponse[typing.Iterator[typing.List[TestSuiteTestCaseBulkResult]]]:
208
+ try:
209
+ if 200 <= _response.status_code < 300:
210
+
211
+ def _iter():
212
+ for _text in _response.iter_lines():
213
+ try:
214
+ if len(_text) == 0:
215
+ continue
216
+ yield typing.cast(
217
+ typing.List[TestSuiteTestCaseBulkResult],
218
+ parse_obj_as(
219
+ type_=typing.List[TestSuiteTestCaseBulkResult], # type: ignore
220
+ object_=json.loads(_text),
221
+ ),
222
+ )
223
+ except Exception:
224
+ pass
225
+ return
226
+
227
+ return HttpResponse(response=_response, data=_iter())
228
+ _response.read()
229
+ _response_json = _response.json()
230
+ except JSONDecodeError:
231
+ raise ApiError(status_code=_response.status_code, body=_response.text)
232
+ raise ApiError(status_code=_response.status_code, body=_response_json)
233
+
234
+ yield stream()
235
+
166
236
  def delete_test_suite_test_case(
167
237
  self, id: str, test_case_id: str, *, request_options: typing.Optional[RequestOptions] = None
168
238
  ) -> HttpResponse[None]:
@@ -343,6 +413,72 @@ class AsyncRawTestSuitesClient:
343
413
  raise ApiError(status_code=_response.status_code, body=_response.text)
344
414
  raise ApiError(status_code=_response.status_code, body=_response_json)
345
415
 
416
+ @contextlib.asynccontextmanager
417
+ async def test_suite_test_cases_bulk(
418
+ self,
419
+ id: str,
420
+ *,
421
+ request: typing.Sequence[TestSuiteTestCaseBulkOperationRequest],
422
+ request_options: typing.Optional[RequestOptions] = None,
423
+ ) -> typing.AsyncIterator[AsyncHttpResponse[typing.AsyncIterator[typing.List[TestSuiteTestCaseBulkResult]]]]:
424
+ """
425
+ Created, replace, and delete Test Cases within the specified Test Suite in bulk
426
+
427
+ Parameters
428
+ ----------
429
+ id : str
430
+ Either the Test Suites' ID or its unique name
431
+
432
+ request : typing.Sequence[TestSuiteTestCaseBulkOperationRequest]
433
+
434
+ request_options : typing.Optional[RequestOptions]
435
+ Request-specific configuration.
436
+
437
+ Yields
438
+ ------
439
+ typing.AsyncIterator[AsyncHttpResponse[typing.AsyncIterator[typing.List[TestSuiteTestCaseBulkResult]]]]
440
+
441
+ """
442
+ async with self._client_wrapper.httpx_client.stream(
443
+ f"v1/test-suites/{jsonable_encoder(id)}/test-cases-bulk",
444
+ base_url=self._client_wrapper.get_environment().default,
445
+ method="POST",
446
+ json=convert_and_respect_annotation_metadata(
447
+ object_=request, annotation=typing.Sequence[TestSuiteTestCaseBulkOperationRequest], direction="write"
448
+ ),
449
+ request_options=request_options,
450
+ omit=OMIT,
451
+ ) as _response:
452
+
453
+ async def stream() -> AsyncHttpResponse[typing.AsyncIterator[typing.List[TestSuiteTestCaseBulkResult]]]:
454
+ try:
455
+ if 200 <= _response.status_code < 300:
456
+
457
+ async def _iter():
458
+ async for _text in _response.aiter_lines():
459
+ try:
460
+ if len(_text) == 0:
461
+ continue
462
+ yield typing.cast(
463
+ typing.List[TestSuiteTestCaseBulkResult],
464
+ parse_obj_as(
465
+ type_=typing.List[TestSuiteTestCaseBulkResult], # type: ignore
466
+ object_=json.loads(_text),
467
+ ),
468
+ )
469
+ except Exception:
470
+ pass
471
+ return
472
+
473
+ return AsyncHttpResponse(response=_response, data=_iter())
474
+ await _response.aread()
475
+ _response_json = _response.json()
476
+ except JSONDecodeError:
477
+ raise ApiError(status_code=_response.status_code, body=_response.text)
478
+ raise ApiError(status_code=_response.status_code, body=_response_json)
479
+
480
+ yield await stream()
481
+
346
482
  async def delete_test_suite_test_case(
347
483
  self, id: str, test_case_id: str, *, request_options: typing.Optional[RequestOptions] = None
348
484
  ) -> AsyncHttpResponse[None]:
@@ -40,7 +40,7 @@ class WorkflowDeploymentsClient:
40
40
  """
41
41
  return self._raw_client
42
42
 
43
- def list_(
43
+ def list(
44
44
  self,
45
45
  *,
46
46
  limit: typing.Optional[int] = None,
@@ -85,11 +85,7 @@ class WorkflowDeploymentsClient:
85
85
  client.workflow_deployments.list()
86
86
  """
87
87
  response = self._raw_client.list(
88
- limit=limit,
89
- offset=offset,
90
- ordering=ordering,
91
- status=status,
92
- request_options=request_options,
88
+ limit=limit, offset=offset, ordering=ordering, status=status, request_options=request_options
93
89
  )
94
90
  return response.data
95
91
 
@@ -122,10 +118,7 @@ class WorkflowDeploymentsClient:
122
118
  id="id",
123
119
  )
124
120
  """
125
- response = self._raw_client.retrieve(
126
- id,
127
- request_options=request_options,
128
- )
121
+ response = self._raw_client.retrieve(id, request_options=request_options)
129
122
  return response.data
130
123
 
131
124
  def list_workflow_deployment_event_executions(
@@ -171,11 +164,7 @@ class WorkflowDeploymentsClient:
171
164
  )
172
165
  """
173
166
  response = self._raw_client.list_workflow_deployment_event_executions(
174
- id,
175
- filters=filters,
176
- limit=limit,
177
- offset=offset,
178
- request_options=request_options,
167
+ id, filters=filters, limit=limit, offset=offset, request_options=request_options
179
168
  )
180
169
  return response.data
181
170
 
@@ -211,9 +200,7 @@ class WorkflowDeploymentsClient:
211
200
  )
212
201
  """
213
202
  response = self._raw_client.workflow_deployment_event_execution(
214
- execution_id,
215
- id,
216
- request_options=request_options,
203
+ execution_id, id, request_options=request_options
217
204
  )
218
205
  return response.data
219
206
 
@@ -254,9 +241,7 @@ class WorkflowDeploymentsClient:
254
241
  )
255
242
  """
256
243
  response = self._raw_client.workflow_deployment_history_item_retrieve(
257
- history_id_or_release_tag,
258
- id,
259
- request_options=request_options,
244
+ history_id_or_release_tag, id, request_options=request_options
260
245
  )
261
246
  return response.data
262
247
 
@@ -310,12 +295,7 @@ class WorkflowDeploymentsClient:
310
295
  )
311
296
  """
312
297
  response = self._raw_client.list_workflow_release_tags(
313
- id,
314
- limit=limit,
315
- offset=offset,
316
- ordering=ordering,
317
- source=source,
318
- request_options=request_options,
298
+ id, limit=limit, offset=offset, ordering=ordering, source=source, request_options=request_options
319
299
  )
320
300
  return response.data
321
301
 
@@ -354,11 +334,7 @@ class WorkflowDeploymentsClient:
354
334
  name="name",
355
335
  )
356
336
  """
357
- response = self._raw_client.retrieve_workflow_release_tag(
358
- id,
359
- name,
360
- request_options=request_options,
361
- )
337
+ response = self._raw_client.retrieve_workflow_release_tag(id, name, request_options=request_options)
362
338
  return response.data
363
339
 
364
340
  def update_workflow_release_tag(
@@ -405,10 +381,7 @@ class WorkflowDeploymentsClient:
405
381
  )
406
382
  """
407
383
  response = self._raw_client.update_workflow_release_tag(
408
- id,
409
- name,
410
- history_item_id=history_item_id,
411
- request_options=request_options,
384
+ id, name, history_item_id=history_item_id, request_options=request_options
412
385
  )
413
386
  return response.data
414
387
 
@@ -448,9 +421,7 @@ class WorkflowDeploymentsClient:
448
421
  )
449
422
  """
450
423
  response = self._raw_client.retrieve_workflow_deployment_release(
451
- id,
452
- release_id_or_release_tag,
453
- request_options=request_options,
424
+ id, release_id_or_release_tag, request_options=request_options
454
425
  )
455
426
  return response.data
456
427
 
@@ -470,7 +441,7 @@ class AsyncWorkflowDeploymentsClient:
470
441
  """
471
442
  return self._raw_client
472
443
 
473
- async def list_(
444
+ async def list(
474
445
  self,
475
446
  *,
476
447
  limit: typing.Optional[int] = None,
@@ -523,11 +494,7 @@ class AsyncWorkflowDeploymentsClient:
523
494
  asyncio.run(main())
524
495
  """
525
496
  response = await self._raw_client.list(
526
- limit=limit,
527
- offset=offset,
528
- ordering=ordering,
529
- status=status,
530
- request_options=request_options,
497
+ limit=limit, offset=offset, ordering=ordering, status=status, request_options=request_options
531
498
  )
532
499
  return response.data
533
500
 
@@ -570,10 +537,7 @@ class AsyncWorkflowDeploymentsClient:
570
537
 
571
538
  asyncio.run(main())
572
539
  """
573
- response = await self._raw_client.retrieve(
574
- id,
575
- request_options=request_options,
576
- )
540
+ response = await self._raw_client.retrieve(id, request_options=request_options)
577
541
  return response.data
578
542
 
579
543
  async def list_workflow_deployment_event_executions(
@@ -627,11 +591,7 @@ class AsyncWorkflowDeploymentsClient:
627
591
  asyncio.run(main())
628
592
  """
629
593
  response = await self._raw_client.list_workflow_deployment_event_executions(
630
- id,
631
- filters=filters,
632
- limit=limit,
633
- offset=offset,
634
- request_options=request_options,
594
+ id, filters=filters, limit=limit, offset=offset, request_options=request_options
635
595
  )
636
596
  return response.data
637
597
 
@@ -675,9 +635,7 @@ class AsyncWorkflowDeploymentsClient:
675
635
  asyncio.run(main())
676
636
  """
677
637
  response = await self._raw_client.workflow_deployment_event_execution(
678
- execution_id,
679
- id,
680
- request_options=request_options,
638
+ execution_id, id, request_options=request_options
681
639
  )
682
640
  return response.data
683
641
 
@@ -726,9 +684,7 @@ class AsyncWorkflowDeploymentsClient:
726
684
  asyncio.run(main())
727
685
  """
728
686
  response = await self._raw_client.workflow_deployment_history_item_retrieve(
729
- history_id_or_release_tag,
730
- id,
731
- request_options=request_options,
687
+ history_id_or_release_tag, id, request_options=request_options
732
688
  )
733
689
  return response.data
734
690
 
@@ -790,12 +746,7 @@ class AsyncWorkflowDeploymentsClient:
790
746
  asyncio.run(main())
791
747
  """
792
748
  response = await self._raw_client.list_workflow_release_tags(
793
- id,
794
- limit=limit,
795
- offset=offset,
796
- ordering=ordering,
797
- source=source,
798
- request_options=request_options,
749
+ id, limit=limit, offset=offset, ordering=ordering, source=source, request_options=request_options
799
750
  )
800
751
  return response.data
801
752
 
@@ -842,11 +793,7 @@ class AsyncWorkflowDeploymentsClient:
842
793
 
843
794
  asyncio.run(main())
844
795
  """
845
- response = await self._raw_client.retrieve_workflow_release_tag(
846
- id,
847
- name,
848
- request_options=request_options,
849
- )
796
+ response = await self._raw_client.retrieve_workflow_release_tag(id, name, request_options=request_options)
850
797
  return response.data
851
798
 
852
799
  async def update_workflow_release_tag(
@@ -901,10 +848,7 @@ class AsyncWorkflowDeploymentsClient:
901
848
  asyncio.run(main())
902
849
  """
903
850
  response = await self._raw_client.update_workflow_release_tag(
904
- id,
905
- name,
906
- history_item_id=history_item_id,
907
- request_options=request_options,
851
+ id, name, history_item_id=history_item_id, request_options=request_options
908
852
  )
909
853
  return response.data
910
854
 
@@ -952,8 +896,6 @@ class AsyncWorkflowDeploymentsClient:
952
896
  asyncio.run(main())
953
897
  """
954
898
  response = await self._raw_client.retrieve_workflow_deployment_release(
955
- id,
956
- release_id_or_release_tag,
957
- request_options=request_options,
899
+ id, release_id_or_release_tag, request_options=request_options
958
900
  )
959
901
  return response.data
@@ -56,10 +56,7 @@ class WorkflowExecutionsClient:
56
56
  execution_id="execution_id",
57
57
  )
58
58
  """
59
- response = self._raw_client.retrieve_workflow_execution_detail(
60
- execution_id,
61
- request_options=request_options,
62
- )
59
+ response = self._raw_client.retrieve_workflow_execution_detail(execution_id, request_options=request_options)
63
60
  return response.data
64
61
 
65
62
 
@@ -115,7 +112,6 @@ class AsyncWorkflowExecutionsClient:
115
112
  asyncio.run(main())
116
113
  """
117
114
  response = await self._raw_client.retrieve_workflow_execution_detail(
118
- execution_id,
119
- request_options=request_options,
115
+ execution_id, request_options=request_options
120
116
  )
121
117
  return response.data
@@ -146,11 +146,7 @@ class WorkflowSandboxesClient:
146
146
  client.workflow_sandboxes.list_workflow_sandbox_examples()
147
147
  """
148
148
  response = self._raw_client.list_workflow_sandbox_examples(
149
- limit=limit,
150
- offset=offset,
151
- ordering=ordering,
152
- tag=tag,
153
- request_options=request_options,
149
+ limit=limit, offset=offset, ordering=ordering, tag=tag, request_options=request_options
154
150
  )
155
151
  return response.data
156
152
 
@@ -299,10 +295,6 @@ class AsyncWorkflowSandboxesClient:
299
295
  asyncio.run(main())
300
296
  """
301
297
  response = await self._raw_client.list_workflow_sandbox_examples(
302
- limit=limit,
303
- offset=offset,
304
- ordering=ordering,
305
- tag=tag,
306
- request_options=request_options,
298
+ limit=limit, offset=offset, ordering=ordering, tag=tag, request_options=request_options
307
299
  )
308
300
  return response.data
@@ -69,7 +69,7 @@ class WorkflowsClient:
69
69
  typing.Iterator[bytes]
70
70
 
71
71
  """
72
- response = self._raw_client.pull(
72
+ with self._raw_client.pull(
73
73
  id,
74
74
  exclude_code=exclude_code,
75
75
  exclude_display=exclude_display,
@@ -77,8 +77,8 @@ class WorkflowsClient:
77
77
  include_sandbox=include_sandbox,
78
78
  strict=strict,
79
79
  request_options=request_options,
80
- )
81
- return response.data
80
+ ) as r:
81
+ yield from r.data
82
82
 
83
83
  def push(
84
84
  self,
@@ -178,7 +178,7 @@ class AsyncWorkflowsClient:
178
178
  typing.AsyncIterator[bytes]
179
179
 
180
180
  """
181
- response = await self._raw_client.pull(
181
+ async with self._raw_client.pull(
182
182
  id,
183
183
  exclude_code=exclude_code,
184
184
  exclude_display=exclude_display,
@@ -186,8 +186,9 @@ class AsyncWorkflowsClient:
186
186
  include_sandbox=include_sandbox,
187
187
  strict=strict,
188
188
  request_options=request_options,
189
- )
190
- return response.data
189
+ ) as r:
190
+ async for data in r.data:
191
+ yield data
191
192
 
192
193
  async def push(
193
194
  self,