Class: Peddler::APIs::FulfillmentInboundV0
- Inherits:
-
Peddler::API
- Object
- Peddler::API
- Peddler::APIs::FulfillmentInboundV0
- Defined in:
- lib/peddler/apis/fulfillment_inbound_v0.rb,
lib/peddler/apis/fulfillment_inbound_v0/error.rb,
lib/peddler/apis/fulfillment_inbound_v0/amount.rb,
lib/peddler/apis/fulfillment_inbound_v0/address.rb,
lib/peddler/apis/fulfillment_inbound_v0/error_list.rb,
lib/peddler/apis/fulfillment_inbound_v0/invalid_sku.rb,
lib/peddler/apis/fulfillment_inbound_v0/invalid_asin.rb,
lib/peddler/apis/fulfillment_inbound_v0/prep_details.rb,
lib/peddler/apis/fulfillment_inbound_v0/invalid_sku_list.rb,
lib/peddler/apis/fulfillment_inbound_v0/invalid_asin_list.rb,
lib/peddler/apis/fulfillment_inbound_v0/prep_details_list.rb,
lib/peddler/apis/fulfillment_inbound_v0/label_download_url.rb,
lib/peddler/apis/fulfillment_inbound_v0/get_labels_response.rb,
lib/peddler/apis/fulfillment_inbound_v0/get_shipments_result.rb,
lib/peddler/apis/fulfillment_inbound_v0/inbound_shipment_info.rb,
lib/peddler/apis/fulfillment_inbound_v0/inbound_shipment_item.rb,
lib/peddler/apis/fulfillment_inbound_v0/inbound_shipment_list.rb,
lib/peddler/apis/fulfillment_inbound_v0/prep_instruction_list.rb,
lib/peddler/apis/fulfillment_inbound_v0/sku_prep_instructions.rb,
lib/peddler/apis/fulfillment_inbound_v0/asin_prep_instructions.rb,
lib/peddler/apis/fulfillment_inbound_v0/get_shipments_response.rb,
lib/peddler/apis/fulfillment_inbound_v0/amazon_prep_fees_details.rb,
lib/peddler/apis/fulfillment_inbound_v0/box_contents_fee_details.rb,
lib/peddler/apis/fulfillment_inbound_v0/get_shipment_items_result.rb,
lib/peddler/apis/fulfillment_inbound_v0/inbound_shipment_item_list.rb,
lib/peddler/apis/fulfillment_inbound_v0/sku_prep_instructions_list.rb,
lib/peddler/apis/fulfillment_inbound_v0/asin_prep_instructions_list.rb,
lib/peddler/apis/fulfillment_inbound_v0/bill_of_lading_download_url.rb,
lib/peddler/apis/fulfillment_inbound_v0/get_bill_of_lading_response.rb,
lib/peddler/apis/fulfillment_inbound_v0/get_shipment_items_response.rb,
lib/peddler/apis/fulfillment_inbound_v0/get_prep_instructions_result.rb,
lib/peddler/apis/fulfillment_inbound_v0/amazon_prep_fees_details_list.rb,
lib/peddler/apis/fulfillment_inbound_v0/get_prep_instructions_response.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.
Defined Under Namespace
Classes: ASINPrepInstructionsList, AmazonPrepFeesDetailsList, ErrorList, InboundShipmentItemList, InboundShipmentList, InvalidASINList, InvalidSKUList, PrepDetailsList, PrepInstructionList, SKUPrepInstructionsList
Constant Summary collapse
- Error =
Error response returned when the request is unsuccessful.
Structure.new do # @return [String] An error code that identifies the type of error that occured. attribute(:code, String) # @return [String] A message that describes the error condition in a human-readable form. attribute(:message, String) # @return [String] Additional details that can help the caller understand or fix the issue. attribute?(:details, String) end
- Amount =
The monetary value.
Structure.new do # @return [String] attribute(:currency_code, String, from: "CurrencyCode") # @return [Float] The amount. attribute(:value, Float, from: "Value") end
- Address =
Specific details to identify a place.
Structure.new do # @return [String] The street address information. attribute(:address_line1, String, from: "AddressLine1") # @return [String] The city. attribute(:city, String, from: "City") # @return [String] The country code in two-character ISO 3166-1 alpha-2 format. attribute(:country_code, String, from: "CountryCode") # @return [String] Name of the individual or business. attribute(:name, String, from: "Name") # @return [String] The postal code. # # If postal codes are used in your marketplace, we recommended that you include one with your request. This # helps Amazon select the most appropriate Amazon fulfillment center for the inbound shipment plan. attribute(:postal_code, String, from: "PostalCode") # @return [String] The state or province code. # # If state or province codes are used in your marketplace, it is recommended that you include one with your # request. This helps Amazon to select the most appropriate Amazon fulfillment center for your inbound shipment # plan. attribute(:state_or_province_code, String, from: "StateOrProvinceCode") # @return [String] Additional street address information, if required. attribute?(:address_line2, String, from: "AddressLine2") # @return [String] The district or county. attribute?(:district_or_county, String, from: "DistrictOrCounty") end
- InvalidSKU =
Contains detail about an invalid SKU
Structure.new do # @return [String] The reason why the seller SKU is invalid. attribute?(:error_reason, String, from: "ErrorReason") # @return [String] The seller SKU of the item. attribute?(:seller_sku, String, from: "SellerSKU") end
- InvalidASIN =
Contains details about an invalid ASIN
Structure.new do # @return [String] The Amazon Standard Identification Number (ASIN) of the item. attribute?(:asin, String, from: "ASIN") # @return [String] The reason that the ASIN is invalid. attribute?(:error_reason, String, from: "ErrorReason") end
- PrepDetails =
Preparation instructions and who is responsible for the preparation.
Structure.new do # @return [String] attribute(:prep_instruction, String, from: "PrepInstruction") # @return [String] attribute(:prep_owner, String, from: "PrepOwner") end
- LabelDownloadURL =
Download URL for a label
Structure.new do # @return [String] URL to download the label for the package. Note: The URL will only be valid for 15 seconds attribute?(:download_url, String, from: "DownloadURL") end
- GetLabelsResponse =
The response schema for the getLabels operation.
Structure.new do # @return [Array<Error>] attribute?(:errors, [Error]) # @return [LabelDownloadURL] The payload for the getLabels operation. attribute?(:payload, LabelDownloadURL) end
- GetShipmentsResult =
Result for the get shipments operation
Structure.new do # @return [String] When present and not empty, pass this string token in the next request to return the next # response page. attribute?(:next_token, String, from: "NextToken") # @return [Array<InboundShipmentInfo>] Information about your inbound shipments. attribute?(:shipment_data, [InboundShipmentInfo], from: "ShipmentData") end
- InboundShipmentInfo =
Information about the seller's inbound shipments. Returned by the listInboundShipments operation.
Structure.new do # @return [:boolean] Indicates whether or not an inbound shipment contains case-packed boxes. When # AreCasesRequired = true for an inbound shipment, all items in the inbound shipment must be case packed. attribute(:are_cases_required, :boolean, from: "AreCasesRequired") # @return [Address] The return address. attribute(:ship_from_address, Address, from: "ShipFromAddress") # @return [String] attribute?(:box_contents_source, String, from: "BoxContentsSource") # @return [String] Date by which the shipment must arrive at the Amazon fulfillment center to avoid delivery # promise breaks for pre-ordered items. attribute?(:confirmed_need_by_date, String, from: "ConfirmedNeedByDate") # @return [String] An Amazon fulfillment center identifier created by Amazon. attribute?(:destination_fulfillment_center_id, String, from: "DestinationFulfillmentCenterId") # @return [BoxContentsFeeDetails] An estimate of the manual processing fee charged by Amazon for boxes without # box content information. This is only returned when BoxContentsSource is NONE. attribute?(:estimated_box_contents_fee, BoxContentsFeeDetails, from: "EstimatedBoxContentsFee") # @return [String] attribute?(:label_prep_type, String, from: "LabelPrepType") # @return [String] The shipment identifier submitted in the request. attribute?(:shipment_id, String, from: "ShipmentId") # @return [String] The name for the inbound shipment. attribute?(:shipment_name, String, from: "ShipmentName") # @return [String] attribute?(:shipment_status, String, from: "ShipmentStatus") end
- InboundShipmentItem =
Item information for an inbound shipment. Submitted with a call to the createInboundShipment or updateInboundShipment operation.
Structure.new do # @return [Integer] The item quantity that you are shipping. attribute(:quantity_shipped, Integer, from: "QuantityShipped") # @return [String] The seller SKU of the item. attribute(:seller_sku, String, from: "SellerSKU") # @return [String] Amazon's fulfillment network SKU of the item. attribute?(:fulfillment_network_sku, String, from: "FulfillmentNetworkSKU") # @return [Array<PrepDetails>] attribute?(:prep_details_list, [PrepDetails], from: "PrepDetailsList") # @return [Integer] The item quantity in each case, for case-packed items. Note that QuantityInCase multiplied # by the number of boxes in the inbound shipment equals QuantityShipped. Also note that all of the boxes of an # inbound shipment must either be case packed or individually packed. For that reason, when you submit the # createInboundShipment or the updateInboundShipment operation, the value of QuantityInCase must be provided for # every item in the shipment or for none of the items in the shipment. attribute?(:quantity_in_case, Integer, from: "QuantityInCase") # @return [Integer] The item quantity that has been received at an Amazon fulfillment center. attribute?(:quantity_received, Integer, from: "QuantityReceived") # @return [String] The date that a pre-order item will be available for sale. attribute?(:release_date, String, from: "ReleaseDate") # @return [String] A shipment identifier originally returned by the createInboundShipmentPlan operation. attribute?(:shipment_id, String, from: "ShipmentId") end
- SKUPrepInstructions =
Labeling requirements and item preparation instructions to help you prepare items for shipment to Amazon's fulfillment network.
Structure.new do # @return [String] The Amazon Standard Identification Number (ASIN) of the item. attribute?(:asin, String, from: "ASIN") # @return [Array<AmazonPrepFeesDetails>] attribute?(:amazon_prep_fees_details_list, [AmazonPrepFeesDetails], from: "AmazonPrepFeesDetailsList") # @return [String] attribute?(:barcode_instruction, String, from: "BarcodeInstruction") # @return [String] attribute?(:prep_guidance, String, from: "PrepGuidance") # @return [Array<PrepInstruction>] attribute?(:prep_instruction_list, Array, from: "PrepInstructionList") # @return [String] The seller SKU of the item. attribute?(:seller_sku, String, from: "SellerSKU") end
- ASINPrepInstructions =
Item preparation instructions to help with item sourcing decisions.
Structure.new do # @return [String] The Amazon Standard Identification Number (ASIN) of the item. attribute?(:asin, String, from: "ASIN") # @return [String] attribute?(:barcode_instruction, String, from: "BarcodeInstruction") # @return [String] attribute?(:prep_guidance, String, from: "PrepGuidance") # @return [Array<PrepInstruction>] attribute?(:prep_instruction_list, Array, from: "PrepInstructionList") end
- GetShipmentsResponse =
The response schema for the getShipments operation.
Structure.new do # @return [Array<Error>] attribute?(:errors, [Error]) # @return [GetShipmentsResult] The payload for the getShipments operation. attribute?(:payload, GetShipmentsResult) end
- AmazonPrepFeesDetails =
The fees for Amazon to prep goods for shipment.
Structure.new do # @return [Amount] The fee for Amazon to prepare 1 unit. attribute?(:fee_per_unit, Amount, from: "FeePerUnit") # @return [String] attribute?(:prep_instruction, String, from: "PrepInstruction") end
- BoxContentsFeeDetails =
The manual processing fee per unit and total fee for a shipment.
Structure.new do # @return [Amount] The manual processing fee per unit. attribute?(:fee_per_unit, Amount, from: "FeePerUnit") # @return [Amount] The total manual processing fee for the shipment. attribute?(:total_fee, Amount, from: "TotalFee") # @return [Integer] The number of units to ship. attribute?(:total_units, Integer, from: "TotalUnits") end
- GetShipmentItemsResult =
Result for the get shipment items operation
Structure.new do # @return [Array<InboundShipmentItem>] A list of item information for an inbound shipment. attribute?(:item_data, [InboundShipmentItem], from: "ItemData") # @return [String] When present and not empty, pass this string token in the next request to return the next # response page. attribute?(:next_token, String, from: "NextToken") end
- BillOfLadingDownloadURL =
Download URL for the bill of lading.
Structure.new do # @return [String] URL to download the bill of lading for the package. Note: The URL will only be valid for 15 # seconds attribute?(:download_url, String, from: "DownloadURL") end
- GetBillOfLadingResponse =
The response schema for the getBillOfLading operation.
Structure.new do # @return [Array<Error>] attribute?(:errors, [Error]) # @return [BillOfLadingDownloadURL] The payload for the getBillOfLading operation. attribute?(:payload, BillOfLadingDownloadURL) end
- GetShipmentItemsResponse =
The response schema for the getShipmentItems operation.
Structure.new do # @return [Array<Error>] attribute?(:errors, [Error]) # @return [GetShipmentItemsResult] The payload for the getShipmentItems operation. attribute?(:payload, GetShipmentItemsResult) end
- GetPrepInstructionsResult =
Result for the get prep instructions operation
Structure.new do # @return [Array<ASINPrepInstructions>] attribute?(:asin_prep_instructions_list, [ASINPrepInstructions], from: "ASINPrepInstructionsList") # @return [Array<InvalidASIN>] attribute?(:invalid_asin_list, [InvalidASIN], from: "InvalidASINList") # @return [Array<InvalidSKU>] attribute?(:invalid_sku_list, [InvalidSKU], from: "InvalidSKUList") # @return [Array<SKUPrepInstructions>] attribute?(:sku_prep_instructions_list, [SKUPrepInstructions], from: "SKUPrepInstructionsList") end
- GetPrepInstructionsResponse =
The response schema for the getPrepInstructions operation.
Structure.new do # @return [Array<Error>] attribute?(:errors, [Error]) # @return [GetPrepInstructionsResult] The payload for the getPrepInstructions operation. attribute?(:payload, GetPrepInstructionsResult) end
Instance Attribute Summary
Attributes inherited from Peddler::API
#access_token, #endpoint, #retries
Instance Method Summary collapse
-
#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_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: nil, 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.
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
#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.
operation.
95 96 97 98 99 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 95 def get_bill_of_lading(shipment_id, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{percent_encode(shipment_id)}/billOfLading" parser = -> { GetBillOfLadingResponse } meter(rate_limit).get(path, parser:) 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.
operation.
supported in your marketplace returns an error.
package labels printed. If you provide box content information with the FBA Inbound Shipment Carton Information
Feed,
then PackageLabelsToPrint
must match the CartonId
values you provide through that feed. If you provide box
content information with the Fulfillment Inbound API v2024-03-20, then PackageLabelsToPrint
must match the
boxID
values from the
listShipmentBoxes
response. If these
values do not match as required, the operation returns the IncorrectPackageIdentifier
error code.
each pallet.
parameter for Non-Partnered LTL Shipments. Max value:1000.
is a required parameter for Non-Partnered LTL Shipments.
70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 70 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/#{percent_encode(shipment_id)}/labels" params = { "PageType" => page_type, "LabelType" => label_type, "NumberOfPackages" => number_of_packages, "PackageLabelsToPrint" => stringify_array(package_labels_to_print), "NumberOfPallets" => number_of_pallets, "PageSize" => page_size, "PageStartIndex" => page_start_index, }.compact parser = -> { GetLabelsResponse } meter(rate_limit).get(path, params:, parser:) 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.
that labeling requirements and item preparation instructions can vary by country. labeling requirements and item preparation instructions for shipment to Amazon's fulfillment network. The SellerSKU is qualified by the Seller ID, which is included with every call to the Seller Partner API. Note: Include seller SKUs that you have used to list items on Amazon's retail website. If you include a seller SKU that you have never used to list an item on Amazon's retail website, the seller SKU is returned in the InvalidSKUList property in the response. preparation instructions to help with item sourcing decisions. Note: ASINs must be included in the product catalog for at least one of the marketplaces that the seller participates in. Any ASIN that is not included in the product catalog for at least one of the marketplaces that the seller participates in is returned in the InvalidASINList property in the response. You can find out which marketplaces a seller participates in by calling the getMarketplaceParticipations operation in the Selling Partner API for Sellers.
34 35 36 37 38 39 40 41 42 43 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 34 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" => stringify_array(seller_sku_list), "ASINList" => stringify_array(asin_list), }.compact parser = -> { GetPrepInstructionsResponse } meter(rate_limit).get(path, params:, parser:) 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.
(or at) a specified time. The selection includes updates made by Amazon and by the seller. before (or at) a specified time. The selection includes updates made by Amazon and by the seller. LastUpdatedAfter and LastUpdatedBefore parameters), or using NextToken, which continues returning items specified in a previous request. stored.
170 171 172 173 174 175 176 177 178 179 180 181 182 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 170 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 parser = -> { GetShipmentItemsResponse } meter(rate_limit).get(path, params:, parser:) end |
#get_shipment_items_by_shipment_id(shipment_id, marketplace_id: 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.
145 146 147 148 149 150 151 152 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 145 def get_shipment_items_by_shipment_id(shipment_id, marketplace_id: nil, rate_limit: 2.0) path = "/fba/inbound/v0/shipments/#{percent_encode(shipment_id)}/items" params = { "MarketplaceId" => marketplace_id, }.compact parser = -> { GetShipmentItemsResponse } meter(rate_limit).get(path, params:, parser:) 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.
current status that matches the status values that you specify. both ShipmentStatusList and ShipmentIdList are specified, only shipments that match both parameters are returned. at) a specified time. The selection includes updates made by Amazon and by the seller. (or at) a specified time. The selection includes updates made by Amazon and by the seller. ShipmentStatusList or ShipmentIdList parameters), using a date range (by providing the LastUpdatedAfter and LastUpdatedBefore parameters), or by using NextToken to continue returning items specified in a previous request. stored.
122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 |
# File 'lib/peddler/apis/fulfillment_inbound_v0.rb', line 122 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" => stringify_array(shipment_status_list), "ShipmentIdList" => stringify_array(shipment_id_list), "LastUpdatedAfter" => last_updated_after, "LastUpdatedBefore" => last_updated_before, "QueryType" => query_type, "NextToken" => next_token, "MarketplaceId" => marketplace_id, }.compact parser = -> { GetShipmentsResponse } meter(rate_limit).get(path, params:, parser:) end |