Class: Peddler::APIs::FulfillmentInboundV0
- Inherits:
-
Peddler::API
- Object
- Peddler::API
- Peddler::APIs::FulfillmentInboundV0
- Defined in:
- lib/peddler/apis/fulfillment_inbound_v0.rb
Overview
Selling Partner API for Fulfillment Inbound
The Selling Partner API for Fulfillment Inbound lets you create applications that create and update inbound shipments of inventory to Amazon's fulfillment network.
Instance Attribute Summary
Attributes inherited from Peddler::API
#access_token, #endpoint, #parser
Instance Method Summary collapse
-
#confirm_preorder(shipment_id, need_by_date, marketplace_id, rate_limit: 2.0) ⇒ Peddler::Response
Returns information needed to confirm a shipment for pre-order.
-
#confirm_transport(shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
Confirms that the seller accepts the Amazon-partnered shipping estimate, agrees to allow Amazon to charge their account for the shipping cost, and requests that the Amazon-partnered carrier ship the inbound shipment.
-
#create_inbound_shipment(body, shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
Returns a new inbound shipment based on the specified shipmentId that was returned by the createInboundShipmentPlan operation.
-
#create_inbound_shipment_plan(body, rate_limit: 2.0) ⇒ Peddler::Response
Returns one or more inbound shipment plans, which provide the information you need to create one or more inbound shipments for a set of items that you specify.
-
#estimate_transport(shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
Initiates the process of estimating the shipping cost for an inbound shipment by an Amazon-partnered carrier.
-
#get_bill_of_lading(shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
Returns a bill of lading for a Less Than Truckload/Full Truckload (LTL/FTL) shipment.
-
#get_labels(shipment_id, page_type, label_type, number_of_packages: nil, package_labels_to_print: nil, number_of_pallets: nil, page_size: nil, page_start_index: nil, rate_limit: 2.0) ⇒ Peddler::Response
Returns package/pallet labels for faster and more accurate shipment processing at the Amazon fulfillment center.
-
#get_preorder_info(shipment_id, marketplace_id, rate_limit: 2.0) ⇒ Peddler::Response
Returns pre-order information, including dates, that a seller needs before confirming a shipment for pre-order.
-
#get_prep_instructions(ship_to_country_code, seller_sku_list: nil, asin_list: nil, rate_limit: 2.0) ⇒ Peddler::Response
Returns labeling requirements and item preparation instructions to help prepare items for shipment to Amazon's fulfillment network.
-
#get_shipment_items(query_type, marketplace_id, last_updated_after: nil, last_updated_before: nil, next_token: nil, rate_limit: 2.0) ⇒ Peddler::Response
Returns a list of items in a specified inbound shipment, or a list of items that were updated within a specified time frame.
-
#get_shipment_items_by_shipment_id(shipment_id, marketplace_id, rate_limit: 2.0) ⇒ Peddler::Response
Returns a list of items in a specified inbound shipment.
-
#get_shipments(query_type, marketplace_id, shipment_status_list: nil, shipment_id_list: nil, last_updated_after: nil, last_updated_before: nil, next_token: nil, rate_limit: 2.0) ⇒ Peddler::Response
Returns a list of inbound shipments based on criteria that you specify.
-
#get_transport_details(shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
Returns current transportation information about an inbound shipment.
-
#put_transport_details(shipment_id, body, rate_limit: 2.0) ⇒ Peddler::Response
Sends transportation information to Amazon about an inbound shipment.
-
#update_inbound_shipment(body, shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
Updates or removes items from the inbound shipment identified by the specified shipment identifier.
-
#void_transport(shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
Cancels a previously-confirmed request to ship an inbound shipment using an Amazon-partnered carrier.
Methods inherited from Peddler::API
#endpoint_uri, #http, #initialize, #meter, #retriable, #sandbox, #sandbox?, #use, #via
Constructor Details
This class inherits a constructor from Peddler::API
Instance Method Details
#confirm_preorder(shipment_id, need_by_date, marketplace_id, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns information needed to confirm a shipment for pre-order. Call this operation after calling the getPreorderInfo operation to get the NeedByDate value and other pre-order information about the shipment.
94 95 96 97 98 99 100 101 102 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 94 def confirm_preorder(shipment_id, need_by_date, marketplace_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}/preorder/confirm" params = { "NeedByDate" => need_by_date, "MarketplaceId" => marketplace_id, }.compact meter(rate_limit).put(path, params:) end |
#confirm_transport(shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Confirms that the seller accepts the Amazon-partnered shipping estimate, agrees to allow Amazon to charge their account for the shipping cost, and requests that the Amazon-partnered carrier ship the inbound shipment. Prior to calling the confirmTransport operation, you should call the getTransportDetails operation to get the Amazon-partnered shipping estimate. Important: After confirming the transportation request, if the seller decides that they do not want the Amazon-partnered carrier to ship the inbound shipment, you can call the voidTransport operation to cancel the transportation request. Note that for a Small Parcel shipment, the seller has 24 hours after confirming a transportation request to void the transportation request. For a Less Than Truckload/Full Truckload (LTL/FTL) shipment, the seller has one hour after confirming a transportation request to void it. After the grace period has expired the seller's account will be charged for the shipping cost.
210 211 212 213 214 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 210 def confirm_transport(shipment_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}/transport/confirm" meter(rate_limit).post(path) end |
#create_inbound_shipment(body, shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns a new inbound shipment based on the specified shipmentId that was returned by the createInboundShipmentPlan operation.
44 45 46 47 48 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 44 def create_inbound_shipment(body, shipment_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}" meter(rate_limit).post(path, body:) end |
#create_inbound_shipment_plan(body, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns one or more inbound shipment plans, which provide the information you need to create one or more inbound shipments for a set of items that you specify. Multiple inbound shipment plans might be required so that items can be optimally placed in Amazon's fulfillment network—for example, positioning inventory closer to the customer. Alternatively, two inbound shipment plans might be created with the same Amazon fulfillment center destination if the two shipment plans require different processing—for example, items that require labels must be shipped separately from stickerless, commingled inventory.
29 30 31 32 33 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 29 def create_inbound_shipment_plan(body, rate_limit: 2.0) path = "/fba/inbound/v0/plans" meter(rate_limit).post(path, body:) end |
#estimate_transport(shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Initiates the process of estimating the shipping cost for an inbound shipment by an Amazon-partnered carrier. Prior to calling the estimateTransport operation, you must call the putTransportDetails operation to provide Amazon with the transportation information for the inbound shipment.
189 190 191 192 193 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 189 def estimate_transport(shipment_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}/transport/estimate" meter(rate_limit).post(path) end |
#get_bill_of_lading(shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns a bill of lading for a Less Than Truckload/Full Truckload (LTL/FTL) shipment. The getBillOfLading operation returns PDF document data for printing a bill of lading for an Amazon-partnered Less Than Truckload/Full Truckload (LTL/FTL) inbound shipment.
268 269 270 271 272 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 268 def get_bill_of_lading(shipment_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}/billOfLading" meter(rate_limit).get(path) end |
#get_labels(shipment_id, page_type, label_type, number_of_packages: nil, package_labels_to_print: nil, number_of_pallets: nil, page_size: nil, page_start_index: nil, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns package/pallet labels for faster and more accurate shipment processing at the Amazon fulfillment center.
243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 243 def get_labels(shipment_id, page_type, label_type, number_of_packages: nil, package_labels_to_print: nil, number_of_pallets: nil, page_size: nil, page_start_index: nil, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}/labels" params = { "PageType" => page_type, "LabelType" => label_type, "NumberOfPackages" => number_of_packages, "PackageLabelsToPrint" => package_labels_to_print, "NumberOfPallets" => number_of_pallets, "PageSize" => page_size, "PageStartIndex" => page_start_index, }.compact meter(rate_limit).get(path, params:) end |
#get_preorder_info(shipment_id, marketplace_id, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns pre-order information, including dates, that a seller needs before confirming a shipment for pre-order.
73 74 75 76 77 78 79 80 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 73 def get_preorder_info(shipment_id, marketplace_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}/preorder" params = { "MarketplaceId" => marketplace_id, }.compact meter(rate_limit).get(path, params:) end |
#get_prep_instructions(ship_to_country_code, seller_sku_list: nil, asin_list: nil, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns labeling requirements and item preparation instructions to help prepare items for shipment to Amazon's fulfillment network.
124 125 126 127 128 129 130 131 132 133 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 124 def get_prep_instructions(ship_to_country_code, seller_sku_list: nil, asin_list: nil, rate_limit: 2.0) path = "/fba/inbound/v0/prepInstructions" params = { "ShipToCountryCode" => ship_to_country_code, "SellerSKUList" => seller_sku_list, "ASINList" => asin_list, }.compact meter(rate_limit).get(path, params:) end |
#get_shipment_items(query_type, marketplace_id, last_updated_after: nil, last_updated_before: nil, next_token: nil, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns a list of items in a specified inbound shipment, or a list of items that were updated within a specified time frame.
344 345 346 347 348 349 350 351 352 353 354 355 356 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 344 def get_shipment_items(query_type, marketplace_id, last_updated_after: nil, last_updated_before: nil, next_token: nil, rate_limit: 2.0) path = "/fba/inbound/v0/shipmentItems" params = { "LastUpdatedAfter" => last_updated_after, "LastUpdatedBefore" => last_updated_before, "QueryType" => query_type, "NextToken" => next_token, "MarketplaceId" => marketplace_id, }.compact meter(rate_limit).get(path, params:) end |
#get_shipment_items_by_shipment_id(shipment_id, marketplace_id, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns a list of items in a specified inbound shipment.
319 320 321 322 323 324 325 326 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 319 def get_shipment_items_by_shipment_id(shipment_id, marketplace_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}/items" params = { "MarketplaceId" => marketplace_id, }.compact meter(rate_limit).get(path, params:) end |
#get_shipments(query_type, marketplace_id, shipment_status_list: nil, shipment_id_list: nil, last_updated_after: nil, last_updated_before: nil, next_token: nil, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns a list of inbound shipments based on criteria that you specify.
295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 295 def get_shipments(query_type, marketplace_id, shipment_status_list: nil, shipment_id_list: nil, last_updated_after: nil, last_updated_before: nil, next_token: nil, rate_limit: 2.0) path = "/fba/inbound/v0/shipments" params = { "ShipmentStatusList" => shipment_status_list, "ShipmentIdList" => shipment_id_list, "LastUpdatedAfter" => last_updated_after, "LastUpdatedBefore" => last_updated_before, "QueryType" => query_type, "NextToken" => next_token, "MarketplaceId" => marketplace_id, }.compact meter(rate_limit).get(path, params:) end |
#get_transport_details(shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns current transportation information about an inbound shipment.
142 143 144 145 146 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 142 def get_transport_details(shipment_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}/transport" meter(rate_limit).get(path) end |
#put_transport_details(shipment_id, body, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Sends transportation information to Amazon about an inbound shipment.
156 157 158 159 160 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 156 def put_transport_details(shipment_id, body, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}/transport" meter(rate_limit).put(path, body:) end |
#update_inbound_shipment(body, shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Updates or removes items from the inbound shipment identified by the specified shipment identifier. Adding new items is not supported.
59 60 61 62 63 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 59 def update_inbound_shipment(body, shipment_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}" meter(rate_limit).put(path, body:) end |
#void_transport(shipment_id, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Cancels a previously-confirmed request to ship an inbound shipment using an Amazon-partnered carrier. To be successful, you must call this operation before the VoidDeadline date that is returned by the getTransportDetails operation. Important: The VoidDeadline date is 24 hours after you confirm a Small Parcel shipment transportation request or one hour after you confirm a Less Than Truckload/Full Truckload (LTL/FTL) shipment transportation request. After the void deadline passes, your account will be charged for the shipping cost.
174 175 176 177 178 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 174 def void_transport(shipment_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{shipment_id}/transport/void" meter(rate_limit).post(path) end |