Module: NotificationHub::Channels::Webhook

Defined in:
lib/notification_hub/channels/webhook.rb,
lib/notification_hub/channels/webhook/base.rb,
lib/notification_hub/channels/webhook/httparty.rb

Defined Under Namespace

Classes: Base, Httparty

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.default_gatewayObject

Returns the value of attribute default_gateway.



7
8
9
# File 'lib/notification_hub/channels/webhook.rb', line 7

def default_gateway
  @default_gateway
end

Class Method Details

.send_message(event_code, data, options, gateway = nil) ⇒ Object



9
10
11
12
# File 'lib/notification_hub/channels/webhook.rb', line 9

def send_message(event_code, data, options, gateway = nil)
  gateway ||= default_gateway
  "NotificationHub::Channels::Webhook::#{gateway.to_s.camelize}".constantize.send_message(event_code, data, options)
end