Sha256: 7be4723d8f2567385697b081a72bccab507b40e6803725eb48c1386f3eef09b4

Contents?: true

Size: 485 Bytes

Versions: 2

Compression:

Stored size: 485 Bytes

Contents

module Fulfillment
  module Resources
    module Products
      extend self

      def find(params={})
        response = Request.new("products", { search: params }).get
        Models::Collection.new(Models::Product, response.body)
      end

      def create_or_update(params={})
        response = Request.new("products", params).post
      end

      def update_all(show_id:, params:)
        response = Request.new("products/#{show_id}", params).patch
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
fulfillment-api-1.1.9 lib/fulfillment/resources/products.rb
fulfillment-api-1.1.7 lib/fulfillment/resources/products.rb