CloudWatchClient.put_composite_alarm
rboto-cloudwatch==0.4.0 · Service index · Types
Model summary (excerpt): Creates or updates a composite alarm . When you create a composite alarm, you specify a rule expression for the alarm that takes into account the alarm states of other alarms that you have created. The composite alarm goes into ALARM state only if all conditions of the rule are met. The alarms specified in a composite alarm's rule expression can include metric alarms and other composite...
Install and imports
from rboto import CloudWatchClient
from collections.abc import Sequence
from rboto_cloudwatch.types import (
ActionConfiguration,
Tag,
)
Signature
async def put_composite_alarm(
*,
alarm_name: str,
alarm_rule: str,
actions_enabled: bool | None = None,
alarm_actions: Sequence[str] | None = None,
alarm_description: str | None = None,
insufficient_data_actions: Sequence[str] | None = None,
ok_actions: Sequence[str] | None = None,
tags: Sequence[Tag] | None = None,
actions_suppressor: str | None = None,
actions_suppressor_wait_period: int | None = None,
actions_suppressor_extension_period: int | None = None,
action_configuration: ActionConfiguration | None = None,
) -> None: ...
Arguments without defaults are required. None omits an optional request argument. Static types do not validate resource existence, permissions, lengths, ranges, or conditional service requirements.
Arguments
| Argument | Required | Model notes (excerpt) |
|---|---|---|
alarm_name |
Yes | The name for the composite alarm. This name must be unique within the Region. |
alarm_rule |
Yes | An expression that specifies which other alarms are to be evaluated to determine this composite alarm's state. For each alarm that you reference, you designate a function that specifies whether that alarm needs to be in ALARM state, OK state, or INSUFFICIENT_DATA state. You can use operators (AND, OR and NOT) to combine multiple functions in a single expression. You can use parenthesis to... |
actions_enabled |
No | Indicates whether actions should be executed during any changes to the alarm state of the composite alarm. The default is TRUE . |
alarm_actions |
No | The actions to execute when this alarm transitions to the ALARM state from any other state. Each action is specified as an Amazon Resource Name (ARN). Valid Values: ] Amazon SNS actions: arn:aws:sns: region : account-id : sns-topic-name Lambda actions: Invoke the latest version of a Lambda function: arn:aws:lambda: region : account-id :function: function-name Invoke a specific version of a... |
alarm_description |
No | The description for the composite alarm. |
insufficient_data_actions |
No | The actions to execute when this alarm transitions to the INSUFFICIENT_DATA state from any other state. Each action is specified as an Amazon Resource Name (ARN). Valid Values: ] Amazon SNS actions: arn:aws:sns: region : account-id : sns-topic-name Lambda actions: Invoke the latest version of a Lambda function: arn:aws:lambda: region : account-id :function: function-name Invoke a specific... |
ok_actions |
No | The actions to execute when this alarm transitions to an OK state from any other state. Each action is specified as an Amazon Resource Name (ARN). Valid Values: ] Amazon SNS actions: arn:aws:sns: region : account-id : sns-topic-name Lambda actions: Invoke the latest version of a Lambda function: arn:aws:lambda: region : account-id :function: function-name Invoke a specific version of a Lambda... |
tags |
No | A list of key-value pairs to associate with the alarm. You can associate as many as 50 tags with an alarm. To be able to associate tags with the alarm when you create the alarm, you must have the cloudwatch:TagResource permission. Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only... |
actions_suppressor |
No | Actions will be suppressed if the suppressor alarm is in the ALARM state. ActionsSuppressor can be an AlarmName or an Amazon Resource Name (ARN) from an existing alarm. |
actions_suppressor_wait_period |
No | The maximum time in seconds that the composite alarm waits for the suppressor alarm to go into the ALARM state. After this time, the composite alarm performs its actions. WaitPeriod is required only when ActionsSuppressor is specified. |
actions_suppressor_extension_period |
No | The maximum time in seconds that the composite alarm waits after suppressor alarm goes out of the ALARM state. After this time, the composite alarm performs its actions. ExtensionPeriod is required only when ActionsSuppressor is specified. |
action_configuration |
No | Settings that change the content of the notifications and events that the alarm sends when its state changes. These settings apply to the alarm's actions, whichever state triggers them. |
Output
None.
| None means a value can be absent. Output mappings include every declared key; optional input keys may be omitted. Unknown output enum/union variants are not automatically valid inputs.
Related types
Follow these links for nested inputs and outputs; recursive types link back to the same type page.
Pagination and streaming
No generated paginator for this operation.
No output stream.
Errors
Import from rboto_cloudwatch.exceptions:
Other service failures use the service base error; credential, transport and timeout failures use shared errors.