Product Fees

class sp_api.api.ProductFees(marketplace: Marketplaces = Marketplaces.US, *, refresh_token=None, account='default', credentials=None, restricted_data_token=None, proxies=None, verify=True, timeout=None, version=None, credential_providers=None)
Link:

https://github.com/amzn/selling-partner-api-docs/tree/main/references/product-fees-api

get_product_fees_estimate_for_sku(self, seller_sku, price: float, shipping_price=None, currency='USD', is_fba=False, points: dict = dict, **kwargs) ApiResponse

Returns fees for sku

Examples

literal blocks:

ProductFees().get_product_fees_estimate_for_sku("UmaS1", 10, currency='USD', shipping_price=10, is_fba=False,
                                          points={
                                              "PointsNumber": 0,
                                              "PointsMonetaryValue": {
                                                  "CurrencyCode": "USD",
                                                  "Amount": 0
                                              }
                                          })
Parameters:
  • seller_sku

  • price

  • shipping_price

  • currency

  • is_fba

  • points

  • marketplace_id – str | Defaults to self.marketplace_id

  • optional_fulfillment_program

  • force_safe_sku – bool | Force user SKU quote

  • **kwargs

Return type:

ApiResponse

get_product_fees_estimate_for_asin(self, asin, price: float, currency='USD', shipping_price=None, is_fba=False, points: dict = dict, **kwargs) ApiResponse

Returns fees for asin

Examples

literal blocks:

ProductFees().get_product_fees_estimate_for_asin("UmaS1", 10, currency='USD', shipping_price=10, is_fba=False,
                                           points={
                                               "PointsNumber": 0,
                                               "PointsMonetaryValue": {
                                                   "CurrencyCode": "USD",
                                                   "Amount": 0
                                               }
                                           })
Parameters:
  • asin

  • price

  • currency

  • shipping_price

  • is_fba

  • points

  • marketplace_id – str | Defaults to self.marketplace_id

  • optional_fulfillment_program

  • **kwargs

Return type:

ApiResponse

get_product_fees_estimate(self, estimate_requests: List[dict]) ApiResponse

Return fees for multiple products

Examples

literal blocks:

ProductFees().get_product_fees_estimate(
        [
            dict(id_type='ASIN', id_value='B012345678', price=100),
            dict(id_type='ASIN', id_value='B012345678', price=50, is_fba=True),
        ]
    )
Parameters:

estimate_requests – list of dict where the allowed keys are : id_type: str | ASIN or SellerSKU id_value: str price: currency: shipping_price: is_fba: points: marketplace_id: str | Defaults to self.marketplace_id optional_fulfillment_program:

_create_body(price, shipping_price=None, currency='USD', is_fba=False, identifier=None, points: dict = None, marketplace_id: str = None, optional_fulfillment_program: str = None, id_type=None, id_value=None)

Create request body

Parameters:
  • price

  • shipping_price

  • currency

  • is_fba

  • identifier

  • points

Returns: