8 lines
277 B
Ruby
8 lines
277 B
Ruby
|
|
class WebhookJob < ApplicationJob
|
||
|
|
queue_as :medium
|
||
|
|
# There are 3 types of webhooks, account, inbox and agent_bot
|
||
|
|
def perform(url, payload, webhook_type = :account_webhook, user_token = nil)
|
||
|
|
Webhooks::Trigger.execute(url, payload, webhook_type, user_token)
|
||
|
|
end
|
||
|
|
end
|