Feature: Support account/inbox specific webhooks (#562)
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
class Api::V1::Inbox::WebhooksController < Api::BaseController
|
||||
class Api::V1::Account::WebhooksController < Api::BaseController
|
||||
before_action :check_authorization
|
||||
before_action :fetch_webhook, only: [:update, :destroy]
|
||||
|
||||
@@ -23,7 +23,7 @@ class Api::V1::Inbox::WebhooksController < Api::BaseController
|
||||
private
|
||||
|
||||
def webhook_params
|
||||
params.require(:webhook).permit(:account_id, :inbox_id, :urls).merge(urls: params[:urls])
|
||||
params.require(:webhook).permit(:account_id, :inbox_id, :url)
|
||||
end
|
||||
|
||||
def fetch_webhook
|
||||
Reference in New Issue
Block a user