Class: AWSCDK::StepFunctionsTasks::EventBridgePutEventsEntry
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::StepFunctionsTasks::EventBridgePutEventsEntry
- Defined in:
- step_functions_tasks/event_bridge_put_events_entry.rb
Overview
An entry to be sent to EventBridge.
Instance Attribute Summary collapse
-
#detail ⇒ AWSCDK::StepFunctions::TaskInput
readonly
The event body.
-
#detail_type ⇒ String
readonly
Used along with the source field to help identify the fields and values expected in the detail field.
-
#event_bus ⇒ AWSCDK::Interfaces::AWSEvents::IEventBusRef?
readonly
The event bus the entry will be sent to.
-
#source ⇒ String
readonly
The service or application that caused this event to be generated.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(detail:, detail_type:, source:, event_bus: nil) ⇒ EventBridgePutEventsEntry
constructor
A new instance of EventBridgePutEventsEntry.
- #to_jsii ⇒ Object
Constructor Details
#initialize(detail:, detail_type:, source:, event_bus: nil) ⇒ EventBridgePutEventsEntry
Returns a new instance of EventBridgePutEventsEntry.
13 14 15 16 17 18 19 20 21 22 |
# File 'step_functions_tasks/event_bridge_put_events_entry.rb', line 13 def initialize(detail:, detail_type:, source:, event_bus: nil) @detail = detail Jsii::Type.check_type(@detail, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfc3RlcGZ1bmN0aW9ucy5UYXNrSW5wdXQifQ==")), "detail") @detail_type = detail_type Jsii::Type.check_type(@detail_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "detailType") @source = source Jsii::Type.check_type(@source, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "source") @event_bus = event_bus Jsii::Type.check_type(@event_bus, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19ldmVudHMuSUV2ZW50QnVzUmVmIn0=")), "eventBus") unless @event_bus.nil? end |
Instance Attribute Details
#detail ⇒ AWSCDK::StepFunctions::TaskInput (readonly)
The event body.
Can either be provided as an object or as a JSON-serialized string
33 34 35 |
# File 'step_functions_tasks/event_bridge_put_events_entry.rb', line 33 def detail @detail end |
#detail_type ⇒ String (readonly)
Used along with the source field to help identify the fields and values expected in the detail field.
For example, events by CloudTrail have detail type "AWS API Call via CloudTrail"
40 41 42 |
# File 'step_functions_tasks/event_bridge_put_events_entry.rb', line 40 def detail_type @detail_type end |
#event_bus ⇒ AWSCDK::Interfaces::AWSEvents::IEventBusRef? (readonly)
Default: - event is sent to account's default event bus
The event bus the entry will be sent to.
52 53 54 |
# File 'step_functions_tasks/event_bridge_put_events_entry.rb', line 52 def event_bus @event_bus end |
#source ⇒ String (readonly)
The service or application that caused this event to be generated.
Example value: com.example.service
47 48 49 |
# File 'step_functions_tasks/event_bridge_put_events_entry.rb', line 47 def source @source end |
Class Method Details
.jsii_properties ⇒ Object
54 55 56 57 58 59 60 61 |
# File 'step_functions_tasks/event_bridge_put_events_entry.rb', line 54 def self.jsii_properties { :detail => "detail", :detail_type => "detailType", :source => "source", :event_bus => "eventBus", } end |
Instance Method Details
#to_jsii ⇒ Object
63 64 65 66 67 68 69 70 71 72 |
# File 'step_functions_tasks/event_bridge_put_events_entry.rb', line 63 def to_jsii result = {} result.merge!({ "detail" => @detail, "detailType" => @detail_type, "source" => @source, "eventBus" => @event_bus, }) result.compact end |