Lists all workflow definitions in your account with optional filtering and pagination.
Parameters:
-
max_results
(Optional[MaxResults], default:
None
)
–
The maximum number of workflow definitions to return in a single response.
-
next_token
(Optional[NextToken], default:
None
)
–
The token for retrieving the next page of results.
-
sort_order
(Optional[SortOrder], default:
None
)
–
The sort order for the returned workflow definitions (ascending or descending).
Raises:
Source code in docs_src/capo_nova_act/_services/async_nova_act.py
| async def list_workflow_definitions(
self,
*,
config_overrides: Optional[AsyncNovaActClientConfig] = None,
max_results: Optional["capo_nova_act.types.max_results.MaxResults"] = None,
next_token: Optional["capo_nova_act.types.next_token.NextToken"] = None,
sort_order: Optional["capo_nova_act.types.sort_order.SortOrder"] = None,
) -> "capo_nova_act.types.list_workflow_definitions_response.ListWorkflowDefinitionsResponse":
"""<p>Lists all workflow definitions in your account with optional filtering and pagination.</p>
Args:
max_results: <p>The maximum number of workflow definitions to return in a single response.</p>
next_token: <p>The token for retrieving the next page of results.</p>
sort_order: <p>The sort order for the returned workflow definitions (ascending or descending).</p>
Raises:
capo_nova_act.errors.access_denied_exception.AccessDeniedException: <p>You don't have sufficient permissions to perform this action.</p>
capo_nova_act.errors.internal_server_exception.InternalServerException: <p>An internal server error occurred. Please try again later.</p>
capo_nova_act.errors.throttling_exception.ThrottlingException: <p>The request was throttled due to too many requests. Please try again later.</p>
capo_nova_act.errors.validation_exception.ValidationException: <p>The input parameters for the request are invalid.</p>
capo_nova_act.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_nova_act.types.list_workflow_definitions_request.ListWorkflowDefinitionsRequest]",
) -> AsyncOperationResponse[
"capo_nova_act.types.list_workflow_definitions_response.ListWorkflowDefinitionsResponse"
]:
import capo_nova_act._operations.amazon_nova_agents_data_plane.list_workflow_definitions
(
output,
http_response,
) = await capo_nova_act._operations.amazon_nova_agents_data_plane.list_workflow_definitions.async_list_workflow_definitions(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ListWorkflowDefinitions")
)
input_: capo_nova_act.types.list_workflow_definitions_request.ListWorkflowDefinitionsRequest = {}
if max_results is not None:
input_["max_results"] = max_results
if next_token is not None:
input_["next_token"] = next_token
if sort_order is not None:
input_["sort_order"] = sort_order
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|