Skip to main content

alarm

Gets an individual alarm resource

Overview

Namealarm
TypeResource
Descriptionalarm
Idawscc.cloudwatch.alarm

Fields

NameDatatypeDescription
threshold_metric_idstringIn an alarm based on an anomaly detection model, this is the ID of the ANOMALY_DETECTION_BAND function used as the threshold for the alarm.
evaluate_low_sample_count_percentilestringUsed only for alarms based on percentiles.
extended_statisticstringThe percentile statistic for the metric associated with the alarm. Specify a value between p0.0 and p100.
comparison_operatorstringThe arithmetic operation to use when comparing the specified statistic and threshold.
treat_missing_datastringSets how this alarm is to handle missing data points. Valid values are breaching, notBreaching, ignore, and missing.
dimensionsarrayThe dimensions for the metric associated with the alarm. For an alarm based on a math expression, you can't specify Dimensions. Instead, you use Metrics.
periodintegerThe period in seconds, over which the statistic is applied.
evaluation_periodsintegerThe number of periods over which data is compared to the specified threshold.
unitstringThe unit of the metric associated with the alarm.
namespacestringThe namespace of the metric associated with the alarm.
ok_actionsarrayThe actions to execute when this alarm transitions to the OK state from any other state.
alarm_actionsarrayThe list of actions to execute when this alarm transitions into an ALARM state from any other state.
metric_namestringThe name of the metric associated with the alarm.
actions_enabledbooleanIndicates whether actions should be executed during any changes to the alarm state. The default is TRUE.
metricsarrayAn array that enables you to create an alarm based on the result of a metric math expression.
alarm_descriptionstringThe description of the alarm.
alarm_namestringThe name of the alarm.
statisticstringThe statistic for the metric associated with the alarm, other than percentile.
insufficient_data_actionsarrayThe actions to execute when this alarm transitions to the INSUFFICIENT_DATA state from any other state.
arnstringAmazon Resource Name is a unique name for each resource.
datapoints_to_alarmintegerThe number of datapoints that must be breaching to trigger the alarm.
thresholdnumberIn an alarm based on an anomaly detection model, this is the ID of the ANOMALY_DETECTION_BAND function used as the threshold for the alarm.
regionstringAWS region.

Methods

Currently only SELECT is supported for this resource resource.

Example

SELECT
region,
threshold_metric_id,
evaluate_low_sample_count_percentile,
extended_statistic,
comparison_operator,
treat_missing_data,
dimensions,
period,
evaluation_periods,
unit,
namespace,
ok_actions,
alarm_actions,
metric_name,
actions_enabled,
metrics,
alarm_description,
alarm_name,
statistic,
insufficient_data_actions,
arn,
datapoints_to_alarm,
threshold
FROM awscc.cloudwatch.alarm
WHERE data__Identifier = '<AlarmName>';

Permissions

To operate on the alarm resource, the following permissions are required:

Update

cloudwatch:PutMetricAlarm,
cloudwatch:DescribeAlarms

Delete

cloudwatch:DeleteAlarms,
cloudwatch:DescribeAlarms

Read

cloudwatch:DescribeAlarms