Skip to content

list_resource_telemetry async

list_resource_telemetry(
    *,
    config_overrides: Optional[AsyncObservabilityAdminClientConfig] = None,
    resource_identifier_prefix: Optional[ResourceIdentifierPrefix] = None,
    resource_types: Optional[ResourceTypes] = None,
    telemetry_configuration_state: Optional[TelemetryConfigurationState] = None,
    resource_tags: Optional[TagMapInput] = None,
    max_results: Optional[ListResourceTelemetryMaxResults] = None,
    next_token: Optional[NextToken] = None,
) -> ListResourceTelemetryOutput

Returns a list of telemetry configurations for Amazon Web Services resources supported by telemetry config. For more information, see Auditing CloudWatch telemetry configurations.

Parameters:

  • resource_identifier_prefix (Optional[ResourceIdentifierPrefix], default: None ) –

    A string used to filter resources which have a ResourceIdentifier starting with the ResourceIdentifierPrefix.

  • resource_types (Optional[ResourceTypes], default: None ) –

    A list of resource types used to filter resources supported by telemetry config. If this parameter is provided, the service returns the resources in the same order as specified in the request. Currently supported resource types for discovery are:

    • AWS::EC2::Instance

    • AWS::EC2::VPC

    • AWS::Lambda::Function

    • AWS::EKS::Cluster

    • AWS::WAFv2::WebACL

    • AWS::ElasticLoadBalancingV2::LoadBalancer (Network Load Balancers only)

  • telemetry_configuration_state (Optional[TelemetryConfigurationState], default: None ) –

    A key-value pair to filter resources based on the telemetry type and the state of the telemetry configuration. The key is the telemetry type and the value is the state.

  • resource_tags (Optional[TagMapInput], default: None ) –

    A key-value pair to filter resources based on tags associated with the resource. For more information about tags, see What are tags?

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

    A number field used to limit the number of results within the returned list.

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

    The token for the next set of items to return. A previous call generates this token.

Raises:

Source code in docs_src/capo_observabilityadmin/_services/async_observability_admin.py
async def list_resource_telemetry(
    self,
    *,
    config_overrides: Optional[AsyncObservabilityAdminClientConfig] = None,
    resource_identifier_prefix: Optional[
        "capo_observabilityadmin.types.resource_identifier_prefix.ResourceIdentifierPrefix"
    ] = None,
    resource_types: Optional[
        "capo_observabilityadmin.types.resource_types.ResourceTypes"
    ] = None,
    telemetry_configuration_state: Optional[
        "capo_observabilityadmin.types.telemetry_configuration_state.TelemetryConfigurationState"
    ] = None,
    resource_tags: Optional[
        "capo_observabilityadmin.types.tag_map_input.TagMapInput"
    ] = None,
    max_results: Optional[
        "capo_observabilityadmin.types.list_resource_telemetry_max_results.ListResourceTelemetryMaxResults"
    ] = None,
    next_token: Optional[
        "capo_observabilityadmin.types.next_token.NextToken"
    ] = None,
) -> "capo_observabilityadmin.types.list_resource_telemetry_output.ListResourceTelemetryOutput":
    """<p> Returns a list of telemetry configurations for Amazon Web Services resources supported by telemetry config. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/telemetry-config-cloudwatch.html">Auditing CloudWatch telemetry configurations</a>. </p>

    Args:
        resource_identifier_prefix: <p> A string used to filter resources which have a <code>ResourceIdentifier</code> starting with the <code>ResourceIdentifierPrefix</code>. </p>
        resource_types: <p> A list of resource types used to filter resources supported by telemetry config. If this parameter is provided, the service returns the resources in the same order as specified in the request. Currently supported resource types for discovery are:</p> <ul> <li> <p> <code>AWS::EC2::Instance</code> </p> </li> <li> <p> <code>AWS::EC2::VPC</code> </p> </li> <li> <p> <code>AWS::Lambda::Function</code> </p> </li> <li> <p> <code>AWS::EKS::Cluster</code> </p> </li> <li> <p> <code>AWS::WAFv2::WebACL</code> </p> </li> <li> <p> <code>AWS::ElasticLoadBalancingV2::LoadBalancer</code> (Network Load Balancers only)</p> </li> </ul>
        telemetry_configuration_state: <p> A key-value pair to filter resources based on the telemetry type and the state of the telemetry configuration. The key is the telemetry type and the value is the state. </p>
        resource_tags: <p> A key-value pair to filter resources based on tags associated with the resource. For more information about tags, see <a href="https://docs.aws.amazon.com/whitepapers/latest/tagging-best-practices/what-are-tags.html">What are tags?</a> </p>
        max_results: <p> A number field used to limit the number of results within the returned list. </p>
        next_token: <p> The token for the next set of items to return. A previous call generates this token. </p>

    Raises:
        capo_observabilityadmin.errors.access_denied_exception.AccessDeniedException: <p> Indicates you don't have permissions to perform the requested operation. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access.html">Access management for Amazon Web Services resources</a> in the IAM user guide. </p>
        capo_observabilityadmin.errors.internal_server_exception.InternalServerException: <p> Indicates the request has failed to process because of an unknown server error, exception, or failure. </p>
        capo_observabilityadmin.errors.too_many_requests_exception.TooManyRequestsException: <p> The request throughput limit was exceeded. </p>
        capo_observabilityadmin.errors.validation_exception.ValidationException: <p> Indicates input validation failed. Check your request parameters and retry the request. </p>
        capo_observabilityadmin.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_observabilityadmin.types.list_resource_telemetry_input.ListResourceTelemetryInput]",
    ) -> AsyncOperationResponse[
        "capo_observabilityadmin.types.list_resource_telemetry_output.ListResourceTelemetryOutput"
    ]:
        import capo_observabilityadmin._operations.observability_admin.list_resource_telemetry

        (
            output,
            http_response,
        ) = await capo_observabilityadmin._operations.observability_admin.list_resource_telemetry.async_list_resource_telemetry(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("ListResourceTelemetry")
    )
    input_: capo_observabilityadmin.types.list_resource_telemetry_input.ListResourceTelemetryInput = {}
    if resource_identifier_prefix is not None:
        input_["resource_identifier_prefix"] = resource_identifier_prefix
    if resource_types is not None:
        input_["resource_types"] = resource_types
    if telemetry_configuration_state is not None:
        input_["telemetry_configuration_state"] = telemetry_configuration_state
    if resource_tags is not None:
        input_["resource_tags"] = resource_tags
    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