Skip to content

list_experiment_resolved_targets async

list_experiment_resolved_targets(
    experiment_id: ExperimentId,
    *,
    config_overrides: Optional[AsyncfisClientConfig] = None,
    max_results: Optional[ListExperimentResolvedTargetsMaxResults] = None,
    next_token: Optional[NextToken] = None,
    target_name: Optional[TargetName] = None,
) -> ListExperimentResolvedTargetsResponse

Lists the resolved targets information of the specified experiment.

Parameters:

Raises:

Source code in docs_src/capo_fis/_services/async_fis.py
async def list_experiment_resolved_targets(
    self,
    experiment_id: "capo_fis.types.experiment_id.ExperimentId",
    *,
    config_overrides: Optional[AsyncfisClientConfig] = None,
    max_results: Optional[
        "capo_fis.types.list_experiment_resolved_targets_max_results.ListExperimentResolvedTargetsMaxResults"
    ] = None,
    next_token: Optional["capo_fis.types.next_token.NextToken"] = None,
    target_name: Optional["capo_fis.types.target_name.TargetName"] = None,
) -> "capo_fis.types.list_experiment_resolved_targets_response.ListExperimentResolvedTargetsResponse":
    """<p>Lists the resolved targets information of the specified experiment.</p>

    Args:
        experiment_id: <p>The ID of the experiment.</p>
        max_results: <p>The maximum number of results to return with a single call. To retrieve the remaining results, make another call with the returned nextToken value.</p>
        next_token: <p>The token for the next page of results.</p>
        target_name: <p>The name of the target.</p>

    Raises:
        capo_fis.errors.resource_not_found_exception.ResourceNotFoundException: <p>The specified resource cannot be found.</p>
        capo_fis.errors.validation_exception.ValidationException: <p>The specified input is not valid, or fails to satisfy the constraints for the request.</p>
        capo_fis.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_fis.types.list_experiment_resolved_targets_request.ListExperimentResolvedTargetsRequest]",
    ) -> AsyncOperationResponse[
        "capo_fis.types.list_experiment_resolved_targets_response.ListExperimentResolvedTargetsResponse"
    ]:
        import capo_fis._operations.fault_injection_simulator.list_experiment_resolved_targets

        (
            output,
            http_response,
        ) = await capo_fis._operations.fault_injection_simulator.list_experiment_resolved_targets.async_list_experiment_resolved_targets(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("ListExperimentResolvedTargets")
    )
    input_: capo_fis.types.list_experiment_resolved_targets_request.ListExperimentResolvedTargetsRequest = {
        "experiment_id": experiment_id
    }
    if max_results is not None:
        input_["max_results"] = max_results
    if next_token is not None:
        input_["next_token"] = next_token
    if target_name is not None:
        input_["target_name"] = target_name

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output