Class: Noticed::DeliveryMethods::MicrosoftTeams

Inherits:
Noticed::DeliveryMethod show all
Defined in:
lib/noticed/delivery_methods/microsoft_teams.rb

Instance Attribute Summary

Attributes inherited from Noticed::DeliveryMethod

#config, #event, #notification

Instance Method Summary collapse

Methods inherited from Noticed::DeliveryMethod

#evaluate_option, #fetch_constant, #perform

Methods included from ApiClient

#post_request

Instance Method Details

#deliverObject



6
7
8
# File 'lib/noticed/delivery_methods/microsoft_teams.rb', line 6

def deliver
  post_request url, headers: evaluate_option(:headers), json: evaluate_option(:json)
end

#urlObject



10
11
12
# File 'lib/noticed/delivery_methods/microsoft_teams.rb', line 10

def url
  evaluate_option(:url) || Rails.application.credentials.dig(:microsoft_teams, :notification_url)
end