Class: Easybill::Api::Contacts
- Defined in:
- lib/easybill/api/contacts.rb
Constant Summary
Constants inherited from Base
Class Method Summary collapse
- .create(customer_id, data) ⇒ Object
- .destroy(customer_id, id) ⇒ Object
- .find(customer_id, id, query: {}) ⇒ Object
- .list(customer_id, query: {}) ⇒ Object
- .update(customer_id, id, data) ⇒ Object
Methods inherited from Base
Methods included from ResponseHandler
Class Method Details
.create(customer_id, data) ⇒ Object
15 16 17 |
# File 'lib/easybill/api/contacts.rb', line 15 def create(customer_id, data) custom method: :post, path: resource_path(customer_id), data: end |
.destroy(customer_id, id) ⇒ Object
23 24 25 |
# File 'lib/easybill/api/contacts.rb', line 23 def destroy(customer_id, id) custom method: :delete, path: "#{resource_path(customer_id)}/#{id}" end |
.find(customer_id, id, query: {}) ⇒ Object
11 12 13 |
# File 'lib/easybill/api/contacts.rb', line 11 def find(customer_id, id, query: {}) custom method: :get, path: "#{resource_path(customer_id)}/#{id}", query: end |
.list(customer_id, query: {}) ⇒ Object
7 8 9 |
# File 'lib/easybill/api/contacts.rb', line 7 def list(customer_id, query: {}) custom method: :get, path: resource_path(customer_id), query: end |
.update(customer_id, id, data) ⇒ Object
19 20 21 |
# File 'lib/easybill/api/contacts.rb', line 19 def update(customer_id, id, data) custom method: :put, path: "#{resource_path(customer_id)}/#{id}", data: end |