class Nimbu::Endpoints::Products
Public Instance Methods
count(*args)
click to toggle source
# File lib/nimbu-api/endpoints/products.rb, line 32 def count(*args) arguments(args) get_request("/products/count", arguments.params) end
create(*args)
click to toggle source
# File lib/nimbu-api/endpoints/products.rb, line 38 def create(*args) arguments(args) post_request("/products", arguments.params) end
customizations(*args) { |el| ... }
click to toggle source
# File lib/nimbu-api/endpoints/products.rb, line 15 def customizations(*args) arguments(args) response = get_request("/products/customizations", arguments.params) return response unless block_given? response.each { |el| yield el } end
Also aliased as: fields, custom_fields
delete(*args)
click to toggle source
# File lib/nimbu-api/endpoints/products.rb, line 51 def delete(*args) arguments(args, :required => [:product_id]) delete_request("/products/#{product_id}", arguments.params) end
Also aliased as: remove
get(*args)
click to toggle source
# File lib/nimbu-api/endpoints/products.rb, line 25 def get(*args) arguments(args, :required => [:product_id]) get_request("/products/#{product_id}", arguments.params) end
Also aliased as: find
list(*args) { |el| ... }
click to toggle source
# File lib/nimbu-api/endpoints/products.rb, line 6 def list(*args) arguments(args) response = get_request("/products", arguments.params) return response unless block_given? response.each { |el| yield el } end
Also aliased as: all
update(*args)
click to toggle source
# File lib/nimbu-api/endpoints/products.rb, line 44 def update(*args) arguments(args, :required => [:product_id]) patch_request("/products/#{product_id}", arguments.params) end
Also aliased as: edit