Skip to content

list_recovery_plan_executions

list_recovery_plan_executions(
    *,
    config_overrides: Optional[drsClientConfig] = None,
    recovery_plan_arn: Optional[StrictDRSARN] = None,
    status: Optional[RecoveryPlanExecutionStatus] = None,
    max_results: Optional[MaxResultsType] = None,
    next_token: Optional[PaginationToken] = None,
) -> ListRecoveryPlanExecutionsResponse

Lists executions of Recovery Plans, optionally filtered by plan or status.

Parameters:

Raises:

Source code in docs_src/capo_drs/_services/drs.py
def list_recovery_plan_executions(
    self,
    *,
    config_overrides: Optional[drsClientConfig] = None,
    recovery_plan_arn: Optional["capo_drs.types.strict_drsarn.StrictDRSARN"] = None,
    status: Optional[
        "capo_drs.types.recovery_plan_execution_status.RecoveryPlanExecutionStatus"
    ] = None,
    max_results: Optional["capo_drs.types.max_results_type.MaxResultsType"] = None,
    next_token: Optional["capo_drs.types.pagination_token.PaginationToken"] = None,
) -> "capo_drs.types.list_recovery_plan_executions_response.ListRecoveryPlanExecutionsResponse":
    """<p>Lists executions of Recovery Plans, optionally filtered by plan or status.</p>

    Args:
        recovery_plan_arn: <p>Filter executions by Recovery Plan ARN.</p>
        status: <p>Filter executions by status.</p>
        max_results: <p>Maximum number of results to return.</p>
        next_token: <p>The token for the next page of results.</p>

    Raises:
        capo_drs.errors.access_denied_exception.AccessDeniedException: <p>You do not have sufficient access to perform this action.</p>
        capo_drs.errors.internal_server_exception.InternalServerException: <p>The request processing has failed because of an unknown error, exception or failure.</p>
        capo_drs.errors.throttling_exception.ThrottlingException: <p>The request was denied due to request throttling.</p>
        capo_drs.errors.uninitialized_account_exception.UninitializedAccountException: <p>The account performing the request has not been initialized.</p>
        capo_drs.errors.validation_exception.ValidationException: <p>The input fails to satisfy the constraints specified by the AWS service.</p>
        capo_drs.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_drs.types.list_recovery_plan_executions_request.ListRecoveryPlanExecutionsRequest]",
    ) -> OperationResponse[
        "capo_drs.types.list_recovery_plan_executions_response.ListRecoveryPlanExecutionsResponse"
    ]:
        import capo_drs._operations.elastic_disaster_recovery_service.list_recovery_plan_executions

        output, http_response = (
            capo_drs._operations.elastic_disaster_recovery_service.list_recovery_plan_executions.list_recovery_plan_executions(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("ListRecoveryPlanExecutions")
    )
    input_: capo_drs.types.list_recovery_plan_executions_request.ListRecoveryPlanExecutionsRequest = {}
    if recovery_plan_arn is not None:
        input_["recovery_plan_arn"] = recovery_plan_arn
    if status is not None:
        input_["status"] = status
    if max_results is not None:
        input_["max_results"] = max_results
    if next_token is not None:
        input_["next_token"] = next_token

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output