UNPKG

@pulumi/azure-native

Version:

[![Slack](http://www.pulumi.com/images/docs/badges/slack.svg)](https://slack.pulumi.com) [![NPM version](https://badge.fury.io/js/%40pulumi%2Fazure-native.svg)](https://npmjs.com/package/@pulumi/azure-native) [![Python version](https://badge.fury.io/py/pu

174 lines (173 loc) 6.93 kB
import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * The metric alert resource. * * Uses Azure REST API version 2018-03-01. */ export declare class MetricAlert extends pulumi.CustomResource { /** * Get an existing MetricAlert 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 opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, opts?: pulumi.CustomResourceOptions): MetricAlert; /** * Returns true if the given object is an instance of MetricAlert. 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 MetricAlert; /** * the array of actions that are performed when the alert rule becomes active, and when an alert condition is resolved. */ readonly actions: pulumi.Output<outputs.monitor.MetricAlertActionResponse[] | undefined>; /** * the flag that indicates whether the alert should be auto resolved or not. The default is true. */ readonly autoMitigate: pulumi.Output<boolean | undefined>; /** * The Azure API version of the resource. */ readonly azureApiVersion: pulumi.Output<string>; /** * defines the specific alert criteria information. */ readonly criteria: pulumi.Output<outputs.monitor.MetricAlertMultipleResourceMultipleMetricCriteriaResponse | outputs.monitor.MetricAlertSingleResourceMultipleMetricCriteriaResponse | outputs.monitor.WebtestLocationAvailabilityCriteriaResponse>; /** * the description of the metric alert that will be included in the alert email. */ readonly description: pulumi.Output<string | undefined>; /** * the flag that indicates whether the metric alert is enabled. */ readonly enabled: pulumi.Output<boolean>; /** * how often the metric alert is evaluated represented in ISO 8601 duration format. */ readonly evaluationFrequency: pulumi.Output<string>; /** * the value indicating whether this alert rule is migrated. */ readonly isMigrated: pulumi.Output<boolean>; /** * Last time the rule was updated in ISO8601 format. */ readonly lastUpdatedTime: pulumi.Output<string>; /** * Resource location */ readonly location: pulumi.Output<string>; /** * Azure resource name */ readonly name: pulumi.Output<string>; /** * the list of resource id's that this metric alert is scoped to. You cannot change the scope of a metric rule based on logs. */ readonly scopes: pulumi.Output<string[]>; /** * Alert severity {0, 1, 2, 3, 4} */ readonly severity: pulumi.Output<number>; /** * Resource tags */ readonly tags: pulumi.Output<{ [key: string]: string; } | undefined>; /** * the region of the target resource(s) on which the alert is created/updated. Mandatory if the scope contains a subscription, resource group, or more than one resource. */ readonly targetResourceRegion: pulumi.Output<string | undefined>; /** * the resource type of the target resource(s) on which the alert is created/updated. Mandatory if the scope contains a subscription, resource group, or more than one resource. */ readonly targetResourceType: pulumi.Output<string | undefined>; /** * Azure resource type */ readonly type: pulumi.Output<string>; /** * the period of time (in ISO 8601 duration format) that is used to monitor alert activity based on the threshold. */ readonly windowSize: pulumi.Output<string>; /** * Create a MetricAlert 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: MetricAlertArgs, opts?: pulumi.CustomResourceOptions); } /** * The set of arguments for constructing a MetricAlert resource. */ export interface MetricAlertArgs { /** * the array of actions that are performed when the alert rule becomes active, and when an alert condition is resolved. */ actions?: pulumi.Input<pulumi.Input<inputs.monitor.MetricAlertActionArgs>[]>; /** * the flag that indicates whether the alert should be auto resolved or not. The default is true. */ autoMitigate?: pulumi.Input<boolean>; /** * defines the specific alert criteria information. */ criteria: pulumi.Input<inputs.monitor.MetricAlertMultipleResourceMultipleMetricCriteriaArgs | inputs.monitor.MetricAlertSingleResourceMultipleMetricCriteriaArgs | inputs.monitor.WebtestLocationAvailabilityCriteriaArgs>; /** * the description of the metric alert that will be included in the alert email. */ description?: pulumi.Input<string>; /** * the flag that indicates whether the metric alert is enabled. */ enabled: pulumi.Input<boolean>; /** * how often the metric alert is evaluated represented in ISO 8601 duration format. */ evaluationFrequency: pulumi.Input<string>; /** * Resource location */ location?: pulumi.Input<string>; /** * The name of the resource group. The name is case insensitive. */ resourceGroupName: pulumi.Input<string>; /** * The name of the rule. */ ruleName?: pulumi.Input<string>; /** * the list of resource id's that this metric alert is scoped to. You cannot change the scope of a metric rule based on logs. */ scopes: pulumi.Input<pulumi.Input<string>[]>; /** * Alert severity {0, 1, 2, 3, 4} */ severity: pulumi.Input<number>; /** * Resource tags */ tags?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * the region of the target resource(s) on which the alert is created/updated. Mandatory if the scope contains a subscription, resource group, or more than one resource. */ targetResourceRegion?: pulumi.Input<string>; /** * the resource type of the target resource(s) on which the alert is created/updated. Mandatory if the scope contains a subscription, resource group, or more than one resource. */ targetResourceType?: pulumi.Input<string>; /** * the period of time (in ISO 8601 duration format) that is used to monitor alert activity based on the threshold. */ windowSize: pulumi.Input<string>; }