Skip to content

list_associated_collectors async

list_associated_collectors(
    environment_id: EnvironmentId,
    *,
    config_overrides: Optional[AsyncContinuumClientConfig] = None,
    max_results: Optional[MaxResults] = None,
    next_token: Optional[NextToken] = None,
) -> ListAssociatedCollectorsOutput

Lists the Collectors currently associated with one Environment in ascending collectorId order. Each entry carries the Collector ARN, so a listed association can be passed straight to DisassociateCollector, including when the Collector belongs to another account. An association recorded before Continuum persisted the ARN is omitted from the response, because without the ARN it cannot be acted on.

Parameters:

  • environment_id (EnvironmentId) –

    The unique identifier of the Environment whose associations to list.

  • max_results (Optional[MaxResults], default: None ) –

    Maximum number of associated Collectors to return.

  • next_token (Optional[NextToken], default: None ) –

    Pagination token returned by a prior request.

Raises:

  • AccessDeniedException –

    The request is not authorized. Verify that your credentials and request signature are valid and that you have permission to perform this action.

  • InternalServerException –

    The request couldn't be processed because of an internal server issue. Try again later. If the problem persists, contact AWS Support.

  • ResourceNotFoundException –

    The specified resource was not found. Verify that the resource identifier is correct and that the resource exists.

  • ThrottlingException –

    The request was denied due to request throttling.

  • UnknownServiceError –

    The service returned an error code this client does not model.

Source code in docs_src/capo_continuum/_services/async_continuum.py
async def list_associated_collectors(
    self,
    environment_id: "capo_continuum.types.environment_id.EnvironmentId",
    *,
    config_overrides: Optional[AsyncContinuumClientConfig] = None,
    max_results: Optional["capo_continuum.types.max_results.MaxResults"] = None,
    next_token: Optional["capo_continuum.types.next_token.NextToken"] = None,
) -> "capo_continuum.types.list_associated_collectors_output.ListAssociatedCollectorsOutput":
    """Lists the Collectors currently associated with one Environment in ascending collectorId order. Each entry carries the Collector ARN, so a listed association can be passed straight to DisassociateCollector, including when the Collector belongs to another account. An association recorded before Continuum persisted the ARN is omitted from the response, because without the ARN it cannot be acted on.

    Args:
        environment_id: The unique identifier of the Environment whose associations to list.
        max_results: Maximum number of associated Collectors to return.
        next_token: Pagination token returned by a prior request.

    Raises:
        capo_continuum.errors.access_denied_exception.AccessDeniedException: The request is not authorized. Verify that your credentials and request signature are valid and that you have permission to perform this action.
        capo_continuum.errors.internal_server_exception.InternalServerException: The request couldn't be processed because of an internal server issue. Try again later. If the problem persists, contact AWS Support.
        capo_continuum.errors.resource_not_found_exception.ResourceNotFoundException: The specified resource was not found. Verify that the resource identifier is correct and that the resource exists.
        capo_continuum.errors.throttling_exception.ThrottlingException: The request was denied due to request throttling.
        capo_continuum.errors.validation_exception.ValidationException
        capo_continuum.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_continuum.types.list_associated_collectors_input.ListAssociatedCollectorsInput]",
    ) -> AsyncOperationResponse[
        "capo_continuum.types.list_associated_collectors_output.ListAssociatedCollectorsOutput"
    ]:
        import capo_continuum._operations.continuum_control_plane.list_associated_collectors

        (
            output,
            http_response,
        ) = await capo_continuum._operations.continuum_control_plane.list_associated_collectors.async_list_associated_collectors(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("ListAssociatedCollectors")
    )
    input_: capo_continuum.types.list_associated_collectors_input.ListAssociatedCollectorsInput = {
        "environment_id": environment_id
    }
    if max_results is not None:
        input_["max_results"] = max_results
    if next_token is not None:
        input_["next_token"] = next_token

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