Class: Api::V2::WebhooksController
- Inherits:
-
V2::BaseController
- Object
- V2::BaseController
- Api::V2::WebhooksController
- Includes:
- Api::Version2, ForemanWebhooks::Controller::Parameters::Webhook
- Defined in:
- app/controllers/api/v2/webhooks_controller.rb
Instance Method Summary collapse
Methods included from ForemanWebhooks::Controller::Parameters::Webhook
Instance Method Details
#create ⇒ Object
43 44 45 46 |
# File 'app/controllers/api/v2/webhooks_controller.rb', line 43 def create @webhook = Webhook.new(webhook_params) process_response @webhook.save end |
#destroy ⇒ Object
57 58 59 |
# File 'app/controllers/api/v2/webhooks_controller.rb', line 57 def destroy process_response @webhook.destroy end |
#index ⇒ Object
14 15 16 |
# File 'app/controllers/api/v2/webhooks_controller.rb', line 14 def index @webhooks = resource_scope_for_index end |
#show ⇒ Object
20 |
# File 'app/controllers/api/v2/webhooks_controller.rb', line 20 def show; end |
#update ⇒ Object
51 52 53 |
# File 'app/controllers/api/v2/webhooks_controller.rb', line 51 def update process_response @webhook.update(webhook_params) end |