Class: PostProxy::WebhookEvents::ReactionEventData

Inherits:
Model
  • Object
show all
Defined in:
lib/postproxy/webhook_events.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Model

#to_h

Constructor Details

#initialize(**attrs) ⇒ ReactionEventData

Returns a new instance of ReactionEventData.



87
88
89
90
91
92
93
94
# File 'lib/postproxy/webhook_events.rb', line 87

def initialize(**attrs)
  @message = nil
  @reaction = nil
  @emoji = nil
  @occurred_at = nil
  super
  @message = Message.new(**@message.transform_keys(&:to_sym)) if @message.is_a?(Hash)
end

Instance Attribute Details

#actionObject

Returns the value of attribute action.



85
86
87
# File 'lib/postproxy/webhook_events.rb', line 85

def action
  @action
end

#emojiObject

Returns the value of attribute emoji.



85
86
87
# File 'lib/postproxy/webhook_events.rb', line 85

def emoji
  @emoji
end

#messageObject

Returns the value of attribute message.



85
86
87
# File 'lib/postproxy/webhook_events.rb', line 85

def message
  @message
end

#occurred_atObject

Returns the value of attribute occurred_at.



85
86
87
# File 'lib/postproxy/webhook_events.rb', line 85

def occurred_at
  @occurred_at
end

#reactionObject

Returns the value of attribute reaction.



85
86
87
# File 'lib/postproxy/webhook_events.rb', line 85

def reaction
  @reaction
end

#sender_external_idObject

Returns the value of attribute sender_external_id.



85
86
87
# File 'lib/postproxy/webhook_events.rb', line 85

def sender_external_id
  @sender_external_id
end