product-fees-api-model

AmzSpApi::ProductFeesApiModel - the Ruby gem for the Selling Partner API for Product Fees

The Selling Partner API for Product Fees lets you programmatically retrieve estimated fees for a product. You can then account for those fees in your pricing.

This SDK is automatically generated by the Swagger Codegen project:

Installation

Build a gem

To build the Ruby code into a gem:

gem build product-fees-api-model.gemspec

Then either install the gem locally:

gem install ./product-fees-api-model-0.1.0.gem

(for development, run gem install --dev ./product-fees-api-model-0.1.0.gem to install the development dependencies)

or publish the gem to a gem hosting service, e.g. RubyGems.

Finally add this to the Gemfile:

gem 'product-fees-api-model', '~> 0.1.0'

Install from Git

If the Ruby gem is hosted at a git repository: github.com/GIT_USER_ID/GIT_REPO_ID, then add the following in the Gemfile:

gem 'product-fees-api-model', :git => 'https://github.com/GIT_USER_ID/GIT_REPO_ID.git'

Include the Ruby code directly

Include the Ruby code directly using -I as follows:

ruby -Ilib script.rb

Getting Started

Please follow the installation procedure and then run the following code:

# Load the gem
require 'product-fees-api-model'

api_instance = AmzSpApi::ProductFeesApiModel::FeesApi.new
body = AmzSpApi::ProductFeesApiModel::GetMyFeesEstimateRequest.new # GetMyFeesEstimateRequest |
asin = 'asin_example' # String | The Amazon Standard Identification Number (ASIN) of the item.


begin
  result = api_instance.get_my_fees_estimate_for_asin(body, asin)
  p result
rescue AmzSpApi::ProductFeesApiModel::ApiError => e
  puts "Exception when calling FeesApi->get_my_fees_estimate_for_asin: #{e}"
end

api_instance = AmzSpApi::ProductFeesApiModel::FeesApi.new
body = AmzSpApi::ProductFeesApiModel::GetMyFeesEstimateRequest.new # GetMyFeesEstimateRequest |
seller_sku = 'seller_sku_example' # String | Used to identify an item in the given marketplace. SellerSKU is qualified by the seller's SellerId, which is included with every operation that you submit.


begin
  result = api_instance.get_my_fees_estimate_for_sku(body, seller_sku)
  p result
rescue AmzSpApi::ProductFeesApiModel::ApiError => e
  puts "Exception when calling FeesApi->get_my_fees_estimate_for_sku: #{e}"
end

Documentation for API Endpoints

All URIs are relative to https://sellingpartnerapi-na.amazon.com/

Class | Method | HTTP request | Description ———— | ————- | ————- | ————- AmzSpApi::ProductFeesApiModel::FeesApi | {get_my_fees_estimate_for_asin} | POST /products/fees/v0/items/{Asin}/feesEstimate | AmzSpApi::ProductFeesApiModel::FeesApi | {get_my_fees_estimate_for_sku} | POST /products/fees/v0/listings/{SellerSKU}/feesEstimate |

Documentation for Models

Documentation for Authorization

All endpoints do not require authorization.