Class: Shipwire::Webhooks
Instance Method Summary collapse
- #create(body) ⇒ Object
- #find(id) ⇒ Object
- #list ⇒ Object
- #remove(id) ⇒ Object (also: #delete)
- #update(id, body) ⇒ Object
Methods inherited from Api
Instance Method Details
#create(body) ⇒ Object
7 8 9 |
# File 'lib/shipwire/webhooks.rb', line 7 def create(body) request(:post, 'webhooks', body: body) end |
#find(id) ⇒ Object
11 12 13 |
# File 'lib/shipwire/webhooks.rb', line 11 def find(id) request(:get, "webhooks/#{id}") end |
#list ⇒ Object
3 4 5 |
# File 'lib/shipwire/webhooks.rb', line 3 def list request(:get, 'webhooks') end |
#remove(id) ⇒ Object Also known as: delete
19 20 21 |
# File 'lib/shipwire/webhooks.rb', line 19 def remove(id) request(:delete, "webhooks/#{id}") end |
#update(id, body) ⇒ Object
15 16 17 |
# File 'lib/shipwire/webhooks.rb', line 15 def update(id, body) request(:put, "webhooks/#{id}", body: body) end |