Module: Epages::REST::Sales

Includes:
Utils
Included in:
API
Defined in:
lib/epages/rest/sales.rb

Overview

Instance Method Summary collapse

Methods included from Utils

#epages_id, #format_date, #format_dates_options, #parse_legal_info, #parse_links, #parse_price_info, #parse_product_lowest_price, #parse_product_variations, #parse_suggestions_to_products, #parse_variation_object, #parse_variations, #perform_delete_request, #perform_delete_with_object, #perform_get_request, #perform_get_with_key_and_objects, #perform_get_with_object, #perform_get_with_objects, #perform_multipart_post_with_objects, #perform_patch_with_object, #perform_post_request, #perform_post_with_key_and_objects, #perform_post_with_object, #perform_post_with_objects, #perform_put_request, #perform_put_with_object, #perform_request, #perform_request_with_key_and_objects, #perform_request_with_object, #perform_request_with_objects, #process_thread

Instance Method Details

#sales(options = {}) ⇒ Object

call the API and return an object of SalesSummary implements the call developer.epages.com/apps/api-reference/get-shops-shopid-sales.html

Parameters:

  • options (Hash) (defaults to: {})


13
14
15
16
# File 'lib/epages/rest/sales.rb', line 13

def sales(options = {})
  options[:product_id] = epages_id(options[:product_id]) if options[:product_id]
  perform_get_with_object('/sales', format_dates_options(options), Epages::SalesSummary)
end