Class: Cb::Clients::SavedJobs
Class Method Summary collapse
- .create(args = {}) ⇒ Object
- .delete(args = {}) ⇒ Object
- .get(args = {}) ⇒ Object
- .update(args = {}) ⇒ Object
Methods inherited from Base
Class Method Details
.create(args = {}) ⇒ Object
22 23 24 25 26 |
# File 'lib/cb/clients/saved_jobs.rb', line 22 def create(args = {}) cb_client.cb_put(Cb.configuration.uri_saved_job, body: body(args), headers: headers(args)) end |
.delete(args = {}) ⇒ Object
28 29 30 |
# File 'lib/cb/clients/saved_jobs.rb', line 28 def delete(args = {}) cb_client.cb_delete(uri_with_id(args), body: body(args), headers: headers(args)) end |
.get(args = {}) ⇒ Object
16 17 18 19 20 |
# File 'lib/cb/clients/saved_jobs.rb', line 16 def get(args = {}) uri = Cb.configuration.uri_saved_job uri += "/#{ args[:id] }" if args[:id] cb_client.cb_get(uri, headers: headers(args)) end |
.update(args = {}) ⇒ Object
32 33 34 |
# File 'lib/cb/clients/saved_jobs.rb', line 32 def update(args = {}) cb_client.cb_post(uri_with_id(args), body: body(args), headers: headers(args)) end |