import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Manages an AWS AMP (Managed Prometheus) Anomaly Detector. * * ## Example Usage * * ### Basic Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.amp.Workspace("example", {}); * const exampleAnomalyDetector = new aws.amp.AnomalyDetector("example", { * configuration: { * randomCutForest: { * query: "avg(up)", * }, * }, * missingDataAction: { * skip: true, * }, * alias: "example", * workspaceId: example.id, * }); * ``` * * ### With evaluation interval and labels * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.amp.Workspace("example", {}); * const exampleAnomalyDetector = new aws.amp.AnomalyDetector("example", { * configuration: { * randomCutForest: { * ignoreNearExpectedFromAbove: { * ratio: 1.5, * }, * ignoreNearExpectedFromBelow: { * amount: 2, * }, * query: "avg(up)", * sampleSize: 256, * shingleSize: 4, * }, * }, * missingDataAction: { * markAsAnomaly: true, * }, * alias: "example", * workspaceId: example.id, * evaluationIntervalInSeconds: 120, * labels: { * env: "production", * team: "platform", * }, * }); * ``` * * ## Import * * ### Identity Schema * * #### Required * * * `id` - (String) ID of the Anomaly Detector. * * `workspaceId` - (String) ID of the AMP workspace containing the Anomaly Detector. * * #### Optional * * * `accountId` (String) AWS Account where this resource is managed. * * `region` (String) Region where this resource is managed. * * Using `pulumi import`, import AMP (Managed Prometheus) Anomaly Detector using a comma-delimited string combining `id` and `workspaceId`. For example: * * ```sh * $ pulumi import aws:amp/anomalyDetector:AnomalyDetector example ad-12345678-abcd-1234-abcd-123456789012,ws-12345678-abcd-1234-abcd-123456789012 * ``` */ export declare class AnomalyDetector extends pulumi.CustomResource { /** * Get an existing AnomalyDetector resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: AnomalyDetectorState, opts?: pulumi.CustomResourceOptions): AnomalyDetector; /** * Returns true if the given object is an instance of AnomalyDetector. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is AnomalyDetector; /** * Name of the anomaly detector. */ readonly alias: pulumi.Output; /** * ARN of the Anomaly Detector. */ readonly arn: pulumi.Output; /** * Configuration block for the anomaly detector algorithm. See `configuration` below. */ readonly configuration: pulumi.Output; /** * RFC3339 timestamp of when the anomaly detector was created. */ readonly createdAt: pulumi.Output; /** * Interval in seconds at which the anomaly detector evaluates data. */ readonly evaluationIntervalInSeconds: pulumi.Output; /** * Map of label key-value pairs used to scope the anomaly detector to specific time series. */ readonly labels: pulumi.Output<{ [key: string]: string; }>; /** * Configuration block for the action to take when data is missing. See `missingDataAction` below. */ readonly missingDataAction: pulumi.Output; /** * Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration. */ readonly region: pulumi.Output; /** * Map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. */ readonly tags: pulumi.Output<{ [key: string]: string; } | undefined>; /** * Map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. */ readonly tagsAll: pulumi.Output<{ [key: string]: string; }>; readonly timeouts: pulumi.Output; /** * ID of the AMP workspace in which to create the anomaly detector. * * The following arguments are optional: */ readonly workspaceId: pulumi.Output; /** * Create a AnomalyDetector resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: AnomalyDetectorArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering AnomalyDetector resources. */ export interface AnomalyDetectorState { /** * Name of the anomaly detector. */ alias?: pulumi.Input; /** * ARN of the Anomaly Detector. */ arn?: pulumi.Input; /** * Configuration block for the anomaly detector algorithm. See `configuration` below. */ configuration?: pulumi.Input; /** * RFC3339 timestamp of when the anomaly detector was created. */ createdAt?: pulumi.Input; /** * Interval in seconds at which the anomaly detector evaluates data. */ evaluationIntervalInSeconds?: pulumi.Input; /** * Map of label key-value pairs used to scope the anomaly detector to specific time series. */ labels?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; /** * Configuration block for the action to take when data is missing. See `missingDataAction` below. */ missingDataAction?: pulumi.Input; /** * Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration. */ region?: pulumi.Input; /** * Map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. */ tags?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; /** * Map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block. */ tagsAll?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; timeouts?: pulumi.Input; /** * ID of the AMP workspace in which to create the anomaly detector. * * The following arguments are optional: */ workspaceId?: pulumi.Input; } /** * The set of arguments for constructing a AnomalyDetector resource. */ export interface AnomalyDetectorArgs { /** * Name of the anomaly detector. */ alias: pulumi.Input; /** * Configuration block for the anomaly detector algorithm. See `configuration` below. */ configuration: pulumi.Input; /** * Interval in seconds at which the anomaly detector evaluates data. */ evaluationIntervalInSeconds?: pulumi.Input; /** * Map of label key-value pairs used to scope the anomaly detector to specific time series. */ labels?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; /** * Configuration block for the action to take when data is missing. See `missingDataAction` below. */ missingDataAction: pulumi.Input; /** * Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration. */ region?: pulumi.Input; /** * Map of tags to assign to the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level. */ tags?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; timeouts?: pulumi.Input; /** * ID of the AMP workspace in which to create the anomaly detector. * * The following arguments are optional: */ workspaceId: pulumi.Input; } //# sourceMappingURL=anomalyDetector.d.ts.map