Feature: Twilio Whatsapp Integration (#779)
Twilio Whatsapp Integration Co-authored-by: Sojan <sojan@pepalo.com>
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
# id :bigint not null, primary key
|
||||
# account_sid :string not null
|
||||
# auth_token :string not null
|
||||
# medium :integer default("sms")
|
||||
# phone_number :string not null
|
||||
# created_at :datetime not null
|
||||
# updated_at :datetime not null
|
||||
@@ -23,6 +24,8 @@ class Channel::TwilioSms < ApplicationRecord
|
||||
validates :auth_token, presence: true
|
||||
validates :phone_number, uniqueness: { scope: :account_id }, presence: true
|
||||
|
||||
enum medium: { sms: 0, whatsapp: 1 }
|
||||
|
||||
belongs_to :account
|
||||
|
||||
has_one :inbox, as: :channel, dependent: :destroy
|
||||
|
||||
Reference in New Issue
Block a user