# AWS::APS Construct Library

This module is part of the [AWS Cloud Development Kit](https://github.com/aws/aws-cdk) project.

TypeScript:

```ts
import * as aps from 'aws-cdk-lib/aws-aps';
```

Python:

```python
import aws_cdk.aws_aps as aps
```

Java:

```java
import software.amazon.awscdk.services.aps.*;
```

C# / .NET:

```csharp
using Amazon.CDK.AWS.APS;
```

Golang:

```go
import aps "github.com/aws/aws-cdk-go/awscdk"
```

There are no official hand-written ([L2](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_lib)) constructs for this service yet. Here are some suggestions on how to proceed:

- Search [Construct Hub for APS construct libraries](https://constructs.dev/search?q=aps)
- Use the automatically generated [L1](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_l1_using) constructs, in the same way you would use [the CloudFormation AWS::APS resources](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/AWS_APS.html) directly.

There are no hand-written ([L2](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_lib)) constructs for this service yet.
However, you can still use the automatically generated [L1](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_l1_using) constructs, and use this service exactly as you would using CloudFormation directly.

For more information on the resources and properties available for this service, see the [CloudFormation documentation for AWS::APS](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/AWS_APS.html).

(Read the [CDK Contributing Guide](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and submit an RFC if you are interested in contributing to this construct library.)

## Types

### Constructs (L1)

- [`CfnAnomalyDetector`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnAnomalyDetector.html) Construct (L1) Anomaly detection uses the Random Cut Forest algorithm for time-series analysis.
- [`CfnResourcePolicy`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnResourcePolicy.html) Construct (L1) Use resource-based policies to grant permissions to other AWS accounts or services to access your workspace.
- [`CfnRuleGroupsNamespace`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnRuleGroupsNamespace.html) Construct (L1) The definition of a rule groups namespace in an Amazon Managed Service for Prometheus workspace.
- [`CfnScraper`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.html) Construct (L1) A scraper is a fully-managed agentless collector that discovers and pulls metrics automatically.
- [`CfnWorkspace`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.html) Construct (L1) An Amazon Managed Service for Prometheus workspace is a logical and isolated Prometheus server dedicated to ingesting, storing, and querying your Prometheus-compatible metrics.

### Structs

- [`CfnAnomalyDetector.AnomalyDetectorConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnAnomalyDetector.AnomalyDetectorConfigurationProperty.html) Struct The configuration for the anomaly detection algorithm.
- [`CfnAnomalyDetector.IgnoreNearExpectedProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnAnomalyDetector.IgnoreNearExpectedProperty.html) Struct Configuration for threshold settings that determine when values near expected values should be ignored during anomaly detection.
- [`CfnAnomalyDetector.LabelProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnAnomalyDetector.LabelProperty.html) Struct The Amazon Managed Service for Prometheus metric labels associated with the anomaly detector.
- [`CfnAnomalyDetector.MissingDataActionProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnAnomalyDetector.MissingDataActionProperty.html) Struct Specifies the action to take when data is missing during anomaly detection evaluation.
- [`CfnAnomalyDetector.RandomCutForestConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnAnomalyDetector.RandomCutForestConfigurationProperty.html) Struct Configuration for the Random Cut Forest algorithm used for anomaly detection in time-series data.
- [`CfnAnomalyDetectorProps`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnAnomalyDetectorProps.html) Struct Properties for defining a `CfnAnomalyDetector`.
- [`CfnResourcePolicyProps`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnResourcePolicyProps.html) Struct Properties for defining a `CfnResourcePolicy`.
- [`CfnRuleGroupsNamespaceProps`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnRuleGroupsNamespaceProps.html) Struct Properties for defining a `CfnRuleGroupsNamespace`.
- [`CfnScraper.AmpConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.AmpConfigurationProperty.html) Struct The `AmpConfiguration` structure defines the Amazon Managed Service for Prometheus instance a scraper should send metrics to.
- [`CfnScraper.CloudWatchConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.CloudWatchConfigurationProperty.html) Struct Configuration for CloudWatch metrics destination.
- [`CfnScraper.CloudWatchLogDestinationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.CloudWatchLogDestinationProperty.html) Struct Represents a cloudwatch logs destination for scraper logging.
- [`CfnScraper.ComponentConfigProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.ComponentConfigProperty.html) Struct Configuration settings for a scraper component.
- [`CfnScraper.DestinationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.DestinationProperty.html) Struct Where to send the metrics from a scraper.
- [`CfnScraper.EksConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.EksConfigurationProperty.html) Struct The `EksConfiguration` structure describes the connection to the Amazon EKS cluster from which a scraper collects metrics.
- [`CfnScraper.ExporterConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.ExporterConfigurationProperty.html) Struct Exporter configuration.
- [`CfnScraper.OpenSearchConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.OpenSearchConfigurationProperty.html) Struct Configuration for OpenSearch exporter.
- [`CfnScraper.RoleConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.RoleConfigurationProperty.html) Struct The role configuration in an Amazon Managed Service for Prometheus scraper.
- [`CfnScraper.ScrapeConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.ScrapeConfigurationProperty.html) Struct A scrape configuration for a scraper, base 64 encoded.
- [`CfnScraper.ScraperComponentProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.ScraperComponentProperty.html) Struct A component of a Amazon Managed Service for Prometheus scraper that can be configured for logging.
- [`CfnScraper.ScraperLoggingConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.ScraperLoggingConfigurationProperty.html) Struct Configuration for scraper logging.
- [`CfnScraper.ScraperLoggingDestinationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.ScraperLoggingDestinationProperty.html) Struct The destination where scraper logs are sent.
- [`CfnScraper.SourceProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.SourceProperty.html) Struct The source of collected metrics for a scraper.
- [`CfnScraper.VpcConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraper.VpcConfigurationProperty.html) Struct Configuration for VPC metrics source.
- [`CfnScraperProps`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnScraperProps.html) Struct Properties for defining a `CfnScraper`.
- [`CfnWorkspace.CloudWatchLogDestinationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.CloudWatchLogDestinationProperty.html) Struct Configuration details for logging to CloudWatch Logs.
- [`CfnWorkspace.LabelProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.LabelProperty.html) Struct A label is a name:value pair used to add context to ingested metrics.
- [`CfnWorkspace.LimitsPerLabelSetEntryProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.LimitsPerLabelSetEntryProperty.html) Struct This structure contains the limits that apply to time series that match one label set.
- [`CfnWorkspace.LimitsPerLabelSetProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.LimitsPerLabelSetProperty.html) Struct This defines a label set for the workspace, and defines the ingestion limit for active time series that match that label set.
- [`CfnWorkspace.LoggingConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.LoggingConfigurationProperty.html) Struct Contains information about the rules and alerting logging configuration for the workspace.
- [`CfnWorkspace.LoggingDestinationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.LoggingDestinationProperty.html) Struct The logging destination in an Amazon Managed Service for Prometheus workspace.
- [`CfnWorkspace.LoggingFilterProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.LoggingFilterProperty.html) Struct Filtering criteria that determine which queries are logged.
- [`CfnWorkspace.QueryLoggingConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.QueryLoggingConfigurationProperty.html) Struct The query logging configuration in an Amazon Managed Service for Prometheus workspace.
- [`CfnWorkspace.WorkspaceConfigurationProperty`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.WorkspaceConfigurationProperty.html) Struct Use this structure to define label sets and the ingestion limits for time series that match label sets, and to specify the retention period of the workspace.
- [`CfnWorkspaceProps`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspaceProps.html) Struct Properties for defining a `CfnWorkspace`.
