我试着创建InboundShipment。
client.create_inbound_shipment(id, inbound_shipment_header, inbound_shipment_items)id是由Shipplan创建的shipplan id。
inbound_shipment_header = {:shipment_name=>"kum_03_01_2019_AVP1", :ship_from_address=>{:name=>"xxxx", :address_line1=>"xxxx", :address_line2=>"", :city=>"xxxx", :state_or_province_code=>"XX", :postal_code=>"xxxx", :country_code=>"xxxx"}, :destination_fulfillment_center_id=>"AVP1", :label_prep_preference=>"SELLER_LABEL", :are_cases_required=>false, :shipment_status=>"WORKING", :intended_box_contents_source=>"2D_BARCODE"}
inbound_shipment_items = [{:seller_sku=>"SKU", :quantity=>25, :prep_details=>[{:prep_instruction=>"Labeling", :prep_owner=>"SELLER"}]}]但是它返回错误,如下所示。
#<Peddler::Errors::InvalidRequestException: Error: You must include a valid ShipmentId with a call to the CreateInboundShipment operation. Get ShipmentId values by calling the CreateInboundShipmentPlan operation. The request to CreateInboundShipment must include only items and quantities that have been previously planned through CreateInboundShipmentPlan. If a ShipmentId is not used to create a shipment within 48 hours it will expire.>当我在MWS便签簿上尝试时,它工作正常。
在RubyOnRails上创建入站货件的解决方案是什么?
发布于 2019-03-10 12:00:16
我刚刚解决了这个问题。
编写inbound_shipment_item时出现错误。
inbound_shipment_item应该如下所示。
inbound_shipment_items = [{:seller_sku=>"SKU", :quantity_shipped=>25, :prep_details=>[{:prep_instruction=>"Labeling", :prep_owner=>"SELLER"}]}]https://stackoverflow.com/questions/54937569
复制相似问题