Class: Lago::Api::Resources::WebhookEndpoint
- Inherits:
-
Base
- Object
- Base
- Lago::Api::Resources::WebhookEndpoint
show all
- Defined in:
- lib/lago/api/resources/webhook_endpoint.rb
Instance Attribute Summary
Attributes inherited from Base
#client
Instance Method Summary
collapse
Methods inherited from Base
#create, #destroy, #get, #get_all, #initialize, #update
Instance Method Details
#api_resource ⇒ Object
9
10
11
|
# File 'lib/lago/api/resources/webhook_endpoint.rb', line 9
def api_resource
'webhook_endpoints'
end
|
#root_name ⇒ Object
13
14
15
|
# File 'lib/lago/api/resources/webhook_endpoint.rb', line 13
def root_name
'webhook_endpoint'
end
|
#whitelist_params(params) ⇒ Object
17
18
19
20
21
22
23
24
25
|
# File 'lib/lago/api/resources/webhook_endpoint.rb', line 17
def whitelist_params(params)
result_hash = {}
result_hash[:webhook_url] = params[:webhook_url] if params.key?(:webhook_url)
result_hash[:signature_algo] = params[:signature_algo] if params.key?(:signature_algo)
result_hash[:event_types] = params[:event_types] if params.key?(:event_types)
result_hash[:name] = params[:name] if params.key?(:name)
{ root_name => result_hash }
end
|