Class: Crowdkit::Client::Worksets
- Defined in:
- lib/crowdkit/client/worksets.rb
Instance Attribute Summary
Attributes inherited from API
#auto_pagination, #client, #stored_params
Instance Method Summary collapse
- #bonus(*args) ⇒ Object
- #get(*args) ⇒ Object (also: #find)
- #list(*args) ⇒ Object (also: #all)
Methods inherited from API
#arguments, extract_class_name, #id_key, #initialize, namespace, #set, #with
Methods included from API::RequestMethods
Constructor Details
This class inherits a constructor from Crowdkit::API
Instance Method Details
#bonus(*args) ⇒ Object
15 16 17 18 |
# File 'lib/crowdkit/client/worksets.rb', line 15 def bonus(*args) arguments(args, required: [:workset_id, :amount]) do_put("worksets/#{workset_id}/bonus", {amount: amount}.merge(arguments.params)) end |
#get(*args) ⇒ Object Also known as: find
3 4 5 6 |
# File 'lib/crowdkit/client/worksets.rb', line 3 def get(*args) arguments(args, required: [:workset_id]) do_get("worksets/#{workset_id}") end |
#list(*args) ⇒ Object Also known as: all
9 10 11 12 |
# File 'lib/crowdkit/client/worksets.rb', line 9 def list(*args) arguments(args, required: [:job_id]) do_get("jobs/#{job_id}/worksets", arguments.params) end |