Class: Peddler::APIs::MerchantFulfillmentV0
- Inherits:
-
Peddler::API
- Object
- Peddler::API
- Peddler::APIs::MerchantFulfillmentV0
- Defined in:
- lib/peddler/apis/merchant_fulfillment_v0.rb
Overview
Selling Partner API for Merchant Fulfillment
With the Selling Partner API for Merchant Fulfillment, you can build applications that sellers can use to purchase shipping for non-Prime and Prime orders using Amazon's Buy Shipping Services.
Instance Attribute Summary
Attributes inherited from Peddler::API
#access_token, #endpoint, #retries
Instance Method Summary collapse
-
#cancel_shipment(shipment_id, rate_limit: 1.0) ⇒ Peddler::Response
Cancel the shipment indicated by the specified shipment identifier.
-
#create_shipment(body, rate_limit: 2.0) ⇒ Peddler::Response
Create a shipment with the information provided.
-
#get_additional_seller_inputs(body, rate_limit: 1.0) ⇒ Peddler::Response
Gets a list of additional seller inputs required for a ship method.
-
#get_eligible_shipment_services(body, rate_limit: 6.0) ⇒ Peddler::Response
Returns a list of shipping service offers that satisfy the specified shipment request details.
-
#get_shipment(shipment_id, rate_limit: 1.0) ⇒ Peddler::Response
Returns the shipment information for an existing shipment.
Methods inherited from Peddler::API
#endpoint_uri, #http, #initialize, #meter, #retriable, #sandbox, #sandbox?, #typed, #typed?, #use, #via
Constructor Details
This class inherits a constructor from Peddler::API
Instance Method Details
#cancel_shipment(shipment_id, rate_limit: 1.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Cancel the shipment indicated by the specified shipment identifier.
50 51 52 53 54 |
# File 'lib/peddler/apis/merchant_fulfillment_v0.rb', line 50 def cancel_shipment(shipment_id, rate_limit: 1.0) path = "/mfn/v0/shipments/#{percent_encode(shipment_id)}" parser = Peddler::Types::MerchantFulfillmentV0::CancelShipmentResponse if typed? meter(rate_limit).delete(path, parser:) end |
#create_shipment(body, rate_limit: 2.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Create a shipment with the information provided.
62 63 64 65 66 |
# File 'lib/peddler/apis/merchant_fulfillment_v0.rb', line 62 def create_shipment(body, rate_limit: 2.0) path = "/mfn/v0/shipments" parser = Peddler::Types::MerchantFulfillmentV0::CreateShipmentResponse if typed? meter(rate_limit).post(path, body:, parser:) end |
#get_additional_seller_inputs(body, rate_limit: 1.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Gets a list of additional seller inputs required for a ship method. This is generally used for international shipping.
75 76 77 78 79 |
# File 'lib/peddler/apis/merchant_fulfillment_v0.rb', line 75 def get_additional_seller_inputs(body, rate_limit: 1.0) path = "/mfn/v0/additionalSellerInputs" parser = Peddler::Types::MerchantFulfillmentV0::GetAdditionalSellerInputsResponse if typed? meter(rate_limit).post(path, body:, parser:) end |
#get_eligible_shipment_services(body, rate_limit: 6.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns a list of shipping service offers that satisfy the specified shipment request details.
26 27 28 29 30 |
# File 'lib/peddler/apis/merchant_fulfillment_v0.rb', line 26 def get_eligible_shipment_services(body, rate_limit: 6.0) path = "/mfn/v0/eligibleShippingServices" parser = Peddler::Types::MerchantFulfillmentV0::GetEligibleShipmentServicesResponse if typed? meter(rate_limit).post(path, body:, parser:) end |
#get_shipment(shipment_id, rate_limit: 1.0) ⇒ Peddler::Response
This operation can make a static sandbox call.
Returns the shipment information for an existing shipment.
38 39 40 41 42 |
# File 'lib/peddler/apis/merchant_fulfillment_v0.rb', line 38 def get_shipment(shipment_id, rate_limit: 1.0) path = "/mfn/v0/shipments/#{percent_encode(shipment_id)}" parser = Peddler::Types::MerchantFulfillmentV0::GetShipmentResponse if typed? meter(rate_limit).get(path, parser:) end |