Skip to content

StepFunctionsClient.list_executions

rboto-sfn==0.4.0 · Service index · Types

Model summary (excerpt): Lists all executions of a state machine or a Map Run. You can list all executions related to a state machine by specifying a state machine Amazon Resource Name (ARN), or those related to a Map Run by specifying a Map Run ARN. Using this API action, you can also list all redriven executions. You can also provide a state machine alias ARN or version ARN to list the executions associated with a...

Install and imports

python -m pip install "rboto[sfn]==0.4.0"
from rboto import StepFunctionsClient
from rboto_sfn.types import (
    ExecutionRedriveFilter,
    ExecutionStatus,
    ListExecutionsOutput,
)

Signature

async def list_executions(
    *,
    state_machine_arn: str | None = None,
    status_filter: ExecutionStatus | None = None,
    max_results: int | None = None,
    next_token: str | None = None,
    map_run_arn: str | None = None,
    redrive_filter: ExecutionRedriveFilter | None = None,
) -> ListExecutionsOutput: ...

Arguments without defaults are required. None omits an optional request argument. Static types do not validate resource existence, permissions, lengths, ranges, or conditional service requirements.

Arguments

Argument Required Model notes (excerpt)
state_machine_arn No The Amazon Resource Name (ARN) of the state machine whose executions is listed. You can specify either a mapRunArn or a stateMachineArn , but not both. You can also return a list of executions associated with a specific alias or version , by specifying an alias ARN or a version ARN in the stateMachineArn parameter.
status_filter No If specified, only list the executions whose current execution status matches the given filter. If you provide a PENDING_REDRIVE statusFilter, you must specify mapRunArn . For more information, see Child workflow execution redrive behaviour in the Step Functions Developer Guide . If you provide a stateMachineArn and a PENDING_REDRIVE statusFilter, the API returns a validation exception.
max_results No The maximum number of results that are returned per call. You can use nextToken to obtain further pages of results. The default is 100 and the maximum allowed page size is 1000. A value of 0 uses the default. This is only an upper limit. The actual number of results returned per call might be fewer than the specified maximum.
next_token No If nextToken is returned, there are more results available. The value of nextToken is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error.
map_run_arn No The Amazon Resource Name (ARN) of the Map Run that started the child workflow executions. If the mapRunArn field is specified, a list of all of the child workflow executions started by a Map Run is returned. For more information, see Examining Map Run in the Step Functions Developer Guide . You can specify either a mapRunArn or a stateMachineArn , but not both.
redrive_filter No Sets a filter to list executions based on whether or not they have been redriven. For a Distributed Map, redriveFilter sets a filter to list child workflow executions based on whether or not they have been redriven. If you do not provide a redriveFilter , Step Functions returns a list of both redriven and non-redriven executions. If you provide a state machine ARN in redriveFilter , the API...

Output

ListExecutionsOutput.

Read-only native attributes, accessed as response.field. Collection getters materialize Python values; to_dict() recursively materializes a mapping. Streams are consumed once.

Field Type Presence References
executions list[ExecutionListItemOutput] Always present ExecutionListItemOutput
next_token str | None Always present —

| None means a value can be absent. Output mappings include every declared key; optional input keys may be omitted. Unknown output enum/union variants are not automatically valid inputs.

ExecutionRedriveFilter, ExecutionStatus, ListExecutionsOutput

Follow these links for nested inputs and outputs; recursive types link back to the same type page.

Pagination and streaming

client.paginators.list_executions(...) accepts the same arguments and returns AsyncIterator[ListExecutionsOutput]. Direct calls return one page. Pages preserve the Output representation above.

Input cursors: next_token. Page-size argument: max_results.

No output stream.

Errors

Import from rboto_sfn.exceptions:

InvalidArnError, InvalidTokenError, ResourceNotFoundError, StateMachineDoesNotExistError, StateMachineTypeNotSupportedError, ValidationError.

Other service failures use the service base error; credential, transport and timeout failures use shared errors.

Service guide · Pinned model