Class: AWSCDK::IoTEvents::CfnAlarmModel::SNSProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::IoTEvents::CfnAlarmModel::SNSProperty
- Defined in:
- io_t_events/cfn_alarm_model.rb
Overview
Information required to publish the Amazon SNS message.
Instance Attribute Summary collapse
-
#payload ⇒ AWSCDK::IResolvable, ...
readonly
You can configure the action payload when you send a message as an Amazon SNS push notification.
-
#target_arn ⇒ String
readonly
The ARN of the Amazon SNS target where the message is sent.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(target_arn:, payload: nil) ⇒ SNSProperty
constructor
A new instance of SNSProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(target_arn:, payload: nil) ⇒ SNSProperty
Returns a new instance of SNSProperty.
1824 1825 1826 1827 1828 1829 |
# File 'io_t_events/cfn_alarm_model.rb', line 1824 def initialize(target_arn:, payload: nil) @target_arn = target_arn Jsii::Type.check_type(@target_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "targetArn") @payload = payload.is_a?(Hash) ? ::AWSCDK::IoTEvents::CfnAlarmModel::PayloadProperty.new(**payload.transform_keys(&:to_sym)) : payload Jsii::Type.check_type(@payload, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19pb3RldmVudHMuQ2ZuQWxhcm1Nb2RlbC5QYXlsb2FkUHJvcGVydHkifV19fQ==")), "payload") unless @payload.nil? end |
Instance Attribute Details
#payload ⇒ AWSCDK::IResolvable, ... (readonly)
You can configure the action payload when you send a message as an Amazon SNS push notification.
1840 1841 1842 |
# File 'io_t_events/cfn_alarm_model.rb', line 1840 def payload @payload end |
#target_arn ⇒ String (readonly)
The ARN of the Amazon SNS target where the message is sent.
1835 1836 1837 |
# File 'io_t_events/cfn_alarm_model.rb', line 1835 def target_arn @target_arn end |
Class Method Details
.jsii_properties ⇒ Object
1842 1843 1844 1845 1846 1847 |
# File 'io_t_events/cfn_alarm_model.rb', line 1842 def self.jsii_properties { :target_arn => "targetArn", :payload => "payload", } end |
Instance Method Details
#to_jsii ⇒ Object
1849 1850 1851 1852 1853 1854 1855 1856 |
# File 'io_t_events/cfn_alarm_model.rb', line 1849 def to_jsii result = {} result.merge!({ "targetArn" => @target_arn, "payload" => @payload, }) result.compact end |