peddler 2.4.4 → 2.4.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6c141fcdd828d246b41f5bf226f58774c8ec308a5d07057ba594dc30f0de02d5
4
- data.tar.gz: 2b1b8f93023b5d239d96204aa205faef1e7a4cd1ce59ea309dde713756060c7c
3
+ metadata.gz: d6d04cca2ae15bfa1b30a6cc0d12c2635144395a3981ef0f81fbade475433a1e
4
+ data.tar.gz: 5572b66b7ac592fe3ac9beea26d89068699c33116b91c80e422a5e699638711c
5
5
  SHA512:
6
- metadata.gz: 9917964b5dec46e1e96cf057717891e6de96e7a05bf83b8f8cb95956306e0db6ec5e41c1f2aa7026f4eb8357b1d58740cb669499c83fd356be546e8623a5f90d
7
- data.tar.gz: c300ba54012e53c7bef4fbf6ac1b3ab42548def3e0f5101b39d6394193616e6eb49319932bf938b4fe2caafb7b353c8633d6df4ba3a013333aede70ab3c7b1f0
6
+ metadata.gz: e0293f38c3193aa0f9a8258c2620cf27f7fbc206a4240ccf4b483e51c312db71bcbc10d42ad829174ab1aa83c8017b3b08bc2c082a669e9040c503bf71747fab
7
+ data.tar.gz: ec5af682f45f8c6c7fcf2be530549bc0aeff921d7b8ba6a27ba9a977f26a31734fba3055901c3f1269759a92619a55cf0bd02e6f447f6bd9f0b4c386d641d4e2
data/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
  [![Maintainability](https://api.codeclimate.com/v1/badges/281e6176048f3c0a1ed3/maintainability)](https://codeclimate.com/github/hakanensari/peddler/maintainability)
5
5
  [![Test Coverage](https://api.codeclimate.com/v1/badges/281e6176048f3c0a1ed3/test_coverage)](https://codeclimate.com/github/hakanensari/peddler/test_coverage)
6
6
 
7
- > :boom: Amazon is migrating to the newly-launched Selling Partner API (SP-API). There is no date yet for when MWS APIs will be deprecated. I will add support in Peddler in due course.
7
+ > :boom: Amazon is migrating to the newly-launched Selling Partner API (SP-API) and is no longer granting new users access to the MWS APIs. I hope to add support in Peddler in due course.
8
8
 
9
9
  **Peddler** is a Ruby interface to the [Amazon MWS API](https://developer.amazonservices.com/), a collection of web services that help Amazon sellers programmatically exchange data on their listings, orders, payments, reports, and more.
10
10
 
@@ -12,7 +12,7 @@ To use Amazon MWS, you must have an eligible seller account and [register as a d
12
12
 
13
13
  Amazon has [multiple regions](https://docs.developer.amazonservices.com/en_US/dev_guide/DG_Endpoints.html). Each region requires application developers to register individually. Some MWS API sections may require additional authorisation from Amazon.
14
14
 
15
- ![Peddler](http://f.cl.ly/items/1G1N0A0a0v3a3h241c1Q/peddler.jpg)
15
+ ![Peddler](https://github.com/hakanensari/peddler/blob/main/images/peddler.jpg?raw=true)
16
16
 
17
17
  ## Usage
18
18
 
@@ -145,14 +145,14 @@ You can access the same attributes on `error.response`. See <a href="#throttling
145
145
  With the Easy Ship API, you can build applications that help sellers in India manage and ship their Amazon Easy Ship orders. Your Amazon Easy Ship applications can get available pickup slots; schedule, reschedule, and cancel pickups; and print labels, invoices, and warranties.
146
146
 
147
147
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/easy_ship/EasyShip_Overview.html)
148
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/EasyShip/Client)
148
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/EasyShip/Client)
149
149
 
150
150
  ### Feeds
151
151
 
152
152
  The MWS Feeds API lets you upload inventory and order data to Amazon. You can also use this API to get information about the processing of feeds.
153
153
 
154
154
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/feeds/Feeds_Overview.html)
155
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/Feeds/Client)
155
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/Feeds/Client)
156
156
  - [XML schema docs](https://sellercentral.amazon.com/gp/help/help-page.html?itemID=1611)
157
157
 
158
158
  ### Finances
@@ -160,21 +160,21 @@ The MWS Feeds API lets you upload inventory and order data to Amazon. You can al
160
160
  The MWS Finances API enables you to obtain financial information relevant to your business with Amazon. You can obtain financial events for a given order, financial event group, or date range without having to wait until a statement period closes. You can also obtain financial event groups for a given date range.
161
161
 
162
162
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/finances/Finances_Overview.html)
163
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/Finances/Client)
163
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/Finances/Client)
164
164
 
165
165
  ### Fulfillment Inbound Shipment
166
166
 
167
167
  With the MWS Fulfillment Inbound Shipment API, you can create and update inbound shipments of inventory in the Amazon Fulfillment Network. You can also also request lists of inbound shipments or inbound shipment items based on criteria that you specify.
168
168
 
169
169
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/fba_inbound/FBAInbound_Overview.html)
170
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/FulfillmentInboundShipment/Client)
170
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/FulfillmentInboundShipment/Client)
171
171
 
172
172
  ### Fulfillment Inventory
173
173
 
174
174
  The MWS Fulfillment Inventory API can help you stay up-to-date on the availability of your inventory in the Amazon Fulfillment Network. The Fulfillment Inventory API reports real-time availability information for your Amazon Fulfillment Network inventory regardless of whether you are selling your inventory on Amazon's retail web site or through other retail channels.
175
175
 
176
176
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/fba_inventory/FBAInventory_Overview.html)
177
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/FulfillmentInventory/Client)
177
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/FulfillmentInventory/Client)
178
178
 
179
179
  ### Fulfillment Outbound Shipment
180
180
 
@@ -183,49 +183,49 @@ The MWS Fulfillment Outbound Shipment API enables you to fulfill orders placed t
183
183
  Support for creating and cancelling fulfillment orders has been implemented, but the rest of the API is not supported yet.
184
184
 
185
185
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/fba_outbound/FBAOutbound_Overview.html)
186
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/FulfillmentOutboundShipment/Client)
186
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/FulfillmentOutboundShipment/Client)
187
187
 
188
188
  ### Merchant Fulfillment
189
189
 
190
190
  The Merchant Fulfillment API provides programmatic access to Amazon’s fulfillment shipping services for sellers, including competitive rates with Amazon-partnered carriers. Sellers can find out what shipping services are available by submitting information about a proposed fulfillment shipment, such as package size and weight; shipment origin and destination; and delivery date requirements. Sellers can choose from the shipping service options returned by Amazon, and then receive shipping labels for fulfilling their orders.
191
191
 
192
192
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/merch_fulfill/MerchFulfill_Overview.html)
193
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/MerchantFulfillment/Client)
193
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/MerchantFulfillment/Client)
194
194
 
195
195
  ### Orders
196
196
 
197
197
  With the MWS Orders API, you can list orders created or updated during a time frame you specify or retrieve information about specific orders.
198
198
 
199
199
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/orders-2013-09-01/Orders_Overview.html)
200
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/Orders/Client)
200
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/Orders/Client)
201
201
 
202
202
  ### Products
203
203
 
204
204
  The MWS Products API helps you get information to match your products to existing product listings on Amazon Marketplace websites and to make sourcing and pricing decisions for listing those products on Amazon Marketplace websites.
205
205
 
206
206
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/products/Products_Overview.html)
207
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/Products/Client)
207
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/Products/Client)
208
208
 
209
209
  ### Recommendations
210
210
 
211
211
  The Recommendations API enables you to programmatically retrieve Amazon Selling Coach recommendations by recommendation category. A recommendation is an actionable, timely, and personalized opportunity to increase your sales and performance.
212
212
 
213
213
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/recommendations/Recommendations_Overview.html)
214
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/Recommendations/Client)
214
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/Recommendations/Client)
215
215
 
216
216
  ### Reports
217
217
 
218
218
  The Reports API lets you request reports about your inventory and orders.
219
219
 
220
220
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/reports/Reports_Overview.html)
221
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/Reports/Client)
221
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/Reports/Client)
222
222
 
223
223
  ### Sellers
224
224
 
225
225
  The Sellers API lets sellers retrieve information about their seller account, such as the marketplaces they participate in.
226
226
 
227
227
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/subscriptions/Subscriptions_Overview.html)
228
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/Sellers/Client)
228
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/Sellers/Client)
229
229
 
230
230
  ### Shipment Invoicing
231
231
 
@@ -234,11 +234,11 @@ With the Shipment Invoicing API section (in conjunction with the FBAOutboundShip
234
234
  This functionality is available only in the Brazil marketplace.
235
235
 
236
236
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/shipment_invoicing/ShipmentInvoicing_Overview.html)
237
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/ShipmentInvoicing/Client)
237
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/ShipmentInvoicing/Client)
238
238
 
239
239
  ### Subscriptions
240
240
 
241
241
  The Amazon MWS Subscriptions API section enables you to subscribe to receive notifications that are relevant to your business with Amazon. With the operations in the Subscriptions API section, you can register to receive important information from Amazon without having to poll the Amazon MWS service. Instead, the information is sent directly to you when an event occurs to which you are subscribed.
242
242
 
243
243
  - [Amazon references](https://docs.developer.amazonservices.com/en_US/subscriptions/Subscriptions_Overview.html)
244
- - [Peddler API docs](https://www.rubydoc.info/gems/peddler/MWS/Subscriptions/Client)
244
+ - [Peddler API docs](https://www.rubydoc.info/github/hakanensari/peddler/MWS/Subscriptions/Client)
@@ -113,7 +113,7 @@ module Peddler
113
113
  # @!visibility private
114
114
  def run(&block)
115
115
  opts = build_options
116
- opts.store(:response_block, block) if block_given?
116
+ opts.store(:response_block, block) if block
117
117
  res = post(opts)
118
118
  self.body = nil if res.status == 200
119
119
 
@@ -50,7 +50,7 @@ module Peddler
50
50
  end
51
51
 
52
52
  def summarize
53
- Hash[summary.split("\n\t")[1, 2].map { |line| line.split("\t\t") }]
53
+ summary.split("\n\t")[1, 2].map { |line| line.split("\t\t") }.to_h
54
54
  end
55
55
  end
56
56
  end
@@ -70,7 +70,8 @@ module Peddler
70
70
  ['A2NODRKZP88ZB9', 'SE', 'mws-eu.amazonservices.com'],
71
71
  ['A19VAU5U5O7RUS', 'SG', 'mws-fe.amazonservices.com'],
72
72
  ['A39IBJ37TRP1C6', 'AU', 'mws.amazonservices.com.au'],
73
- ['A1VC38T7YXB528', 'JP', 'mws.amazonservices.jp']
73
+ ['A1VC38T7YXB528', 'JP', 'mws.amazonservices.jp'],
74
+ ['A1C3SOZRARQ6R3', 'PL', 'mws-eu.amazonservices.com']
74
75
  ].map do |values|
75
76
  new(*values)
76
77
  end
@@ -60,7 +60,7 @@ module Peddler
60
60
  end
61
61
 
62
62
  def capitalize(word)
63
- if ALL_CAPS.any? { |val| val == word }
63
+ if ALL_CAPS.any?(word)
64
64
  word.upcase
65
65
  else
66
66
  word.capitalize
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Peddler
4
- VERSION = '2.4.4'
4
+ VERSION = '2.4.5'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: peddler
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.4.4
4
+ version: 2.4.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hakan Ensari
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-10-30 00:00:00.000000000 Z
11
+ date: 2021-04-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: excon
@@ -126,7 +126,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
126
126
  - !ruby/object:Gem::Version
127
127
  version: '0'
128
128
  requirements: []
129
- rubygems_version: 3.1.4
129
+ rubygems_version: 3.2.3
130
130
  signing_key:
131
131
  specification_version: 4
132
132
  summary: A Ruby wrapper to the Amazon MWS API