A Ruby API for http://www.lazada.com.my
Add this line to your application's Gemfile:
gem 'lazada'And then execute:
$ bundle
Or install it yourself as:
$ gem install lazada
The client is the base for all communication with the API.
client = Lazada::Client.new(api_key, user_id)Get all or a range of products.
client.get_products(filter)Possible filter values are all, live, inactive, deleted, image-missing, pending, rejected, sold-out.
Create a new product.
client.create_product({ 'SellerSku' => 'lz001A', ... })Update the attributes of one or more existing products.
client.update_product({ 'SellerSku' => 'lz001A', 'Price' => 12 })Removes one or more products
client.remove_product(seller_sku)Get the list of all product categories.
client.get_categoriesReturns a list of attributes with options for a given category.
cleint.get_category_attributes(primary_cateogory_id)Get the customer details for a range of orders.
client.get_orders({ status: status })Possible status values are pending, canceled, ready_to_ship, delivered, returned, shipped and failed.
Get the order items for a single order.
client.get_order(order_id)Returns the items for one order.
client.get_order_items(order_id)Set the Images for a Product, by associating one or more URLs with it.
client.set_images({ 'ProductImage' => { 'SellerSku' => 'lz001A', 'images' => { ... } } })Returns detailed information about a specified feed.
client.feed_status(feed_id)Returns all feeds created in the last 30 days.
client.feed_listAfter checking out the repo, run bin/setup to install dependencies. You can also run bin/console for an interactive prompt that will allow you to experiment.
To install this gem onto your local machine, run bundle exec rake install. To release a new version, update the version number in version.rb, and then run bundle exec rake release, which will create a git tag for the version, push git commits and tags, and push the .gem file to rubygems.org.
Bug reports and pull requests are welcome on GitHub at https://github.com/yoolk/lazada. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.
The gem is available as open source under the terms of the MIT License.