import * as core from "@terrascript/core"; export interface CompositeAlarmArgs extends core.ResourceArgs { /** * (Optional, Forces new resource) Indicates whether actions should be executed during any changes to t * he alarm state of the composite alarm. Defaults to `true`. */ actionsEnabled?: boolean | core.BooleanOut; /** * (Optional) The set of actions to execute when this alarm transitions to the `ALARM` state from any o * ther state. Each action is specified as an ARN. Up to 5 actions are allowed. */ alarmActions?: core.Array | core.ArrayOut; /** * (Optional) The description for the composite alarm. */ alarmDescription?: string | core.StringOut; /** * (Required) The name for the composite alarm. This name must be unique within the region. */ alarmName: string | core.StringOut; /** * (Required) An expression that specifies which other alarms are to be evaluated to determine this com * posite alarm's state. For syntax, see [Creating a Composite Alarm](https://docs.aws.amazon.com/Amazo * nCloudWatch/latest/monitoring/Create_Composite_Alarm.html). The maximum length is 10240 characters. */ alarmRule: string | core.StringOut; /** * (Optional) The set of actions to execute when this alarm transitions to the `INSUFFICIENT_DATA` stat * e from any other state. Each action is specified as an ARN. Up to 5 actions are allowed. */ insufficientDataActions?: core.Array | core.ArrayOut; /** * (Optional) The set of actions to execute when this alarm transitions to an `OK` state from any other * state. Each action is specified as an ARN. Up to 5 actions are allowed. */ okActions?: core.Array | core.ArrayOut; /** * (Optional) A map of tags to associate with the alarm. Up to 50 tags are allowed. If configured with * a provider [`default_tags` configuration block](https://registry.terraform.io/providers/hashicorp/aw * s/latest/docs#default_tags-configuration-block) present, tags with matching keys will overwrite thos * e defined at the provider-level. */ tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ tagsAll?: core.Map | core.MapOut; } export class CompositeAlarm extends core.Resource { /** * (Optional, Forces new resource) Indicates whether actions should be executed during any changes to t * he alarm state of the composite alarm. Defaults to `true`. */ @core.attr(Boolean) public actionsEnabled?: boolean | core.BooleanOut; /** * (Optional) The set of actions to execute when this alarm transitions to the `ALARM` state from any o * ther state. Each action is specified as an ARN. Up to 5 actions are allowed. */ @core.attr(String, { kind: "array" }) public alarmActions?: core.Array | core.ArrayOut; /** * (Optional) The description for the composite alarm. */ @core.attr(String) public alarmDescription?: string | core.StringOut; /** * (Required) The name for the composite alarm. This name must be unique within the region. */ @core.attr(String) public alarmName!: string | core.StringOut; /** * (Required) An expression that specifies which other alarms are to be evaluated to determine this com * posite alarm's state. For syntax, see [Creating a Composite Alarm](https://docs.aws.amazon.com/Amazo * nCloudWatch/latest/monitoring/Create_Composite_Alarm.html). The maximum length is 10240 characters. */ @core.attr(String) public alarmRule!: string | core.StringOut; /** * The ARN of the composite alarm. */ @core.attr(String, { computed: true }) public arn!: string | core.StringOut; /** * The ID of the composite alarm resource, which is equivalent to its `alarm_name`. */ @core.attr(String, { computed: true }) public id!: string | core.StringOut; /** * (Optional) The set of actions to execute when this alarm transitions to the `INSUFFICIENT_DATA` stat * e from any other state. Each action is specified as an ARN. Up to 5 actions are allowed. */ @core.attr(String, { kind: "array" }) public insufficientDataActions?: | core.Array | core.ArrayOut; /** * (Optional) The set of actions to execute when this alarm transitions to an `OK` state from any other * state. Each action is specified as an ARN. Up to 5 actions are allowed. */ @core.attr(String, { kind: "array" }) public okActions?: core.Array | core.ArrayOut; /** * (Optional) A map of tags to associate with the alarm. Up to 50 tags are allowed. If configured with * a provider [`default_tags` configuration block](https://registry.terraform.io/providers/hashicorp/aw * s/latest/docs#default_tags-configuration-block) present, tags with matching keys will overwrite thos * e defined at the provider-level. */ @core.attr(String, { kind: "map" }) public tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ @core.attr(String, { computed: true, kind: "map" }) public tagsAll?: core.Map | core.MapOut; constructor(name: string, args?: CompositeAlarmArgs) { super(name, "aws_cloudwatch_composite_alarm", args); } public override getNamespace(): string { return "aws_cloudwatch"; } }