Class: MessageSmsNotification
- Inherits:
-
Object
- Object
- MessageSmsNotification
- Defined in:
- app/models/message_sms_notification.rb
Overview
SMS notification service for Messages and Notifications sent to Participants.
Instance Attribute Summary collapse
-
#body ⇒ Object
readonly
Returns the value of attribute body.
-
#phone_number ⇒ Object
readonly
Returns the value of attribute phone_number.
Instance Method Summary collapse
- #deliver ⇒ Object
-
#initialize(body:, phone_number:) ⇒ MessageSmsNotification
constructor
A new instance of MessageSmsNotification.
Constructor Details
#initialize(body:, phone_number:) ⇒ MessageSmsNotification
Returns a new instance of MessageSmsNotification.
5 6 7 8 |
# File 'app/models/message_sms_notification.rb', line 5 def initialize(body:, phone_number:) @body = body @phone_number = phone_number end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body.
3 4 5 |
# File 'app/models/message_sms_notification.rb', line 3 def body @body end |
#phone_number ⇒ Object (readonly)
Returns the value of attribute phone_number.
3 4 5 |
# File 'app/models/message_sms_notification.rb', line 3 def phone_number @phone_number end |
Instance Method Details
#deliver ⇒ Object
10 11 12 13 14 15 16 |
# File 'app/models/message_sms_notification.rb', line 10 def deliver if environment.staging? || environment.production? sms_client.account..create else end end |