@scaleleap/selling-partner-api-sdk
Version:
📦 A fully typed TypeScript and Node.js SDK library for Amazon Selling Partner API
413 lines • 40.6 kB
JavaScript
;
/* tslint:disable */
/* eslint-disable */
/**
* Selling Partner API for FBA Small And Light
* The Selling Partner API for FBA Small and Light lets you help sellers manage their listings in the Small and Light program. The program reduces the cost of fulfilling orders for small and lightweight FBA inventory. You can enroll or remove items from the program and check item eligibility and enrollment status. You can also preview the estimated program fees charged to a seller for items sold while enrolled in the program.
*
* The version of the OpenAPI document: v1
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.SmallAndLightApi = exports.SmallAndLightApiFactory = exports.SmallAndLightApiFp = exports.SmallAndLightApiAxiosParamCreator = exports.SmallAndLightEnrollmentStatus = exports.SmallAndLightEligibilityStatus = exports.FeeLineItemFeeTypeEnum = void 0;
const axios_1 = __importDefault(require("axios"));
// Some imports not used depending on template conditions
// @ts-ignore
const common_1 = require("./common");
// @ts-ignore
const base_1 = require("./base");
/**
* @export
* @enum {string}
*/
var FeeLineItemFeeTypeEnum;
(function (FeeLineItemFeeTypeEnum) {
FeeLineItemFeeTypeEnum["FbaWeightBasedFee"] = "FBAWeightBasedFee";
FeeLineItemFeeTypeEnum["FbaPerOrderFulfillmentFee"] = "FBAPerOrderFulfillmentFee";
FeeLineItemFeeTypeEnum["FbaPerUnitFulfillmentFee"] = "FBAPerUnitFulfillmentFee";
FeeLineItemFeeTypeEnum["Commission"] = "Commission";
})(FeeLineItemFeeTypeEnum || (exports.FeeLineItemFeeTypeEnum = FeeLineItemFeeTypeEnum = {}));
/**
* The Small and Light eligibility status of the item.
* @export
* @enum {string}
*/
var SmallAndLightEligibilityStatus;
(function (SmallAndLightEligibilityStatus) {
SmallAndLightEligibilityStatus["Eligible"] = "ELIGIBLE";
SmallAndLightEligibilityStatus["NotEligible"] = "NOT_ELIGIBLE";
})(SmallAndLightEligibilityStatus || (exports.SmallAndLightEligibilityStatus = SmallAndLightEligibilityStatus = {}));
/**
* The Small and Light enrollment status of the item.
* @export
* @enum {string}
*/
var SmallAndLightEnrollmentStatus;
(function (SmallAndLightEnrollmentStatus) {
SmallAndLightEnrollmentStatus["Enrolled"] = "ENROLLED";
SmallAndLightEnrollmentStatus["NotEnrolled"] = "NOT_ENROLLED";
})(SmallAndLightEnrollmentStatus || (exports.SmallAndLightEnrollmentStatus = SmallAndLightEnrollmentStatus = {}));
/**
* SmallAndLightApi - axios parameter creator
* @export
*/
const SmallAndLightApiAxiosParamCreator = function (configuration) {
return {
/**
* Removes the item indicated by the specified seller SKU from the Small and Light program in the specified marketplace. If the item is not eligible for disenrollment, the ineligibility reasons are returned. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace in which to remove the item from the Small and Light program. Note: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
deleteSmallAndLightEnrollmentBySellerSKU: async (sellerSKU, marketplaceIds, options = {}) => {
// verify required parameter 'sellerSKU' is not null or undefined
(0, common_1.assertParamExists)('deleteSmallAndLightEnrollmentBySellerSKU', 'sellerSKU', sellerSKU);
// verify required parameter 'marketplaceIds' is not null or undefined
(0, common_1.assertParamExists)('deleteSmallAndLightEnrollmentBySellerSKU', 'marketplaceIds', marketplaceIds);
const localVarPath = `/fba/smallAndLight/v1/enrollments/{sellerSKU}`
.replace(`{${"sellerSKU"}}`, encodeURIComponent(String(sellerSKU)));
// use dummy base URL string because the URL constructor only accepts absolute URLs.
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
let baseOptions;
if (configuration) {
baseOptions = configuration.baseOptions;
}
const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options };
const localVarHeaderParameter = {};
const localVarQueryParameter = {};
if (marketplaceIds) {
localVarQueryParameter['marketplaceIds'] = marketplaceIds.join(base_1.COLLECTION_FORMATS.csv);
}
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter, options.query);
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
return {
url: (0, common_1.toPathString)(localVarUrlObj),
options: localVarRequestOptions,
};
},
/**
* Returns the Small and Light program eligibility status of the item indicated by the specified seller SKU in the specified marketplace. If the item is not eligible, the ineligibility reasons are returned. **Note:** The parameters associated with this operation may contain special characters that must be encoded to successfully call the API. To avoid errors with SKUs when encoding URLs, refer to [URL Encoding](https://developer-docs.amazon.com/sp-api/docs/url-encoding). **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 10 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace for which the eligibility status is retrieved. NOTE: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getSmallAndLightEligibilityBySellerSKU: async (sellerSKU, marketplaceIds, options = {}) => {
// verify required parameter 'sellerSKU' is not null or undefined
(0, common_1.assertParamExists)('getSmallAndLightEligibilityBySellerSKU', 'sellerSKU', sellerSKU);
// verify required parameter 'marketplaceIds' is not null or undefined
(0, common_1.assertParamExists)('getSmallAndLightEligibilityBySellerSKU', 'marketplaceIds', marketplaceIds);
const localVarPath = `/fba/smallAndLight/v1/eligibilities/{sellerSKU}`
.replace(`{${"sellerSKU"}}`, encodeURIComponent(String(sellerSKU)));
// use dummy base URL string because the URL constructor only accepts absolute URLs.
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
let baseOptions;
if (configuration) {
baseOptions = configuration.baseOptions;
}
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
const localVarHeaderParameter = {};
const localVarQueryParameter = {};
if (marketplaceIds) {
localVarQueryParameter['marketplaceIds'] = marketplaceIds.join(base_1.COLLECTION_FORMATS.csv);
}
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter, options.query);
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
return {
url: (0, common_1.toPathString)(localVarUrlObj),
options: localVarRequestOptions,
};
},
/**
* Returns the Small and Light enrollment status for the item indicated by the specified seller SKU in the specified marketplace. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 10 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace for which the enrollment status is retrieved. Note: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getSmallAndLightEnrollmentBySellerSKU: async (sellerSKU, marketplaceIds, options = {}) => {
// verify required parameter 'sellerSKU' is not null or undefined
(0, common_1.assertParamExists)('getSmallAndLightEnrollmentBySellerSKU', 'sellerSKU', sellerSKU);
// verify required parameter 'marketplaceIds' is not null or undefined
(0, common_1.assertParamExists)('getSmallAndLightEnrollmentBySellerSKU', 'marketplaceIds', marketplaceIds);
const localVarPath = `/fba/smallAndLight/v1/enrollments/{sellerSKU}`
.replace(`{${"sellerSKU"}}`, encodeURIComponent(String(sellerSKU)));
// use dummy base URL string because the URL constructor only accepts absolute URLs.
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
let baseOptions;
if (configuration) {
baseOptions = configuration.baseOptions;
}
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
const localVarHeaderParameter = {};
const localVarQueryParameter = {};
if (marketplaceIds) {
localVarQueryParameter['marketplaceIds'] = marketplaceIds.join(base_1.COLLECTION_FORMATS.csv);
}
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter, options.query);
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
return {
url: (0, common_1.toPathString)(localVarUrlObj),
options: localVarRequestOptions,
};
},
/**
* Returns the Small and Light fee estimates for the specified items. You must include a marketplaceId parameter to retrieve the proper fee estimates for items to be sold in that marketplace. The ordering of items in the response will mirror the order of the items in the request. Duplicate ASIN/price combinations are removed. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 3 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {SmallAndLightFeePreviewRequest} body
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getSmallAndLightFeePreview: async (body, options = {}) => {
// verify required parameter 'body' is not null or undefined
(0, common_1.assertParamExists)('getSmallAndLightFeePreview', 'body', body);
const localVarPath = `/fba/smallAndLight/v1/feePreviews`;
// use dummy base URL string because the URL constructor only accepts absolute URLs.
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
let baseOptions;
if (configuration) {
baseOptions = configuration.baseOptions;
}
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
const localVarHeaderParameter = {};
const localVarQueryParameter = {};
localVarHeaderParameter['Content-Type'] = 'application/json';
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter, options.query);
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(body, localVarRequestOptions, configuration);
return {
url: (0, common_1.toPathString)(localVarUrlObj),
options: localVarRequestOptions,
};
},
/**
* Enrolls the item indicated by the specified seller SKU in the Small and Light program in the specified marketplace. If the item is not eligible, the ineligibility reasons are returned. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace in which to enroll the item. Note: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
putSmallAndLightEnrollmentBySellerSKU: async (sellerSKU, marketplaceIds, options = {}) => {
// verify required parameter 'sellerSKU' is not null or undefined
(0, common_1.assertParamExists)('putSmallAndLightEnrollmentBySellerSKU', 'sellerSKU', sellerSKU);
// verify required parameter 'marketplaceIds' is not null or undefined
(0, common_1.assertParamExists)('putSmallAndLightEnrollmentBySellerSKU', 'marketplaceIds', marketplaceIds);
const localVarPath = `/fba/smallAndLight/v1/enrollments/{sellerSKU}`
.replace(`{${"sellerSKU"}}`, encodeURIComponent(String(sellerSKU)));
// use dummy base URL string because the URL constructor only accepts absolute URLs.
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
let baseOptions;
if (configuration) {
baseOptions = configuration.baseOptions;
}
const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options };
const localVarHeaderParameter = {};
const localVarQueryParameter = {};
if (marketplaceIds) {
localVarQueryParameter['marketplaceIds'] = marketplaceIds.join(base_1.COLLECTION_FORMATS.csv);
}
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter, options.query);
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
return {
url: (0, common_1.toPathString)(localVarUrlObj),
options: localVarRequestOptions,
};
},
};
};
exports.SmallAndLightApiAxiosParamCreator = SmallAndLightApiAxiosParamCreator;
/**
* SmallAndLightApi - functional programming interface
* @export
*/
const SmallAndLightApiFp = function (configuration) {
const localVarAxiosParamCreator = (0, exports.SmallAndLightApiAxiosParamCreator)(configuration);
return {
/**
* Removes the item indicated by the specified seller SKU from the Small and Light program in the specified marketplace. If the item is not eligible for disenrollment, the ineligibility reasons are returned. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace in which to remove the item from the Small and Light program. Note: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async deleteSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options) {
const localVarAxiosArgs = await localVarAxiosParamCreator.deleteSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options);
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
},
/**
* Returns the Small and Light program eligibility status of the item indicated by the specified seller SKU in the specified marketplace. If the item is not eligible, the ineligibility reasons are returned. **Note:** The parameters associated with this operation may contain special characters that must be encoded to successfully call the API. To avoid errors with SKUs when encoding URLs, refer to [URL Encoding](https://developer-docs.amazon.com/sp-api/docs/url-encoding). **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 10 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace for which the eligibility status is retrieved. NOTE: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async getSmallAndLightEligibilityBySellerSKU(sellerSKU, marketplaceIds, options) {
const localVarAxiosArgs = await localVarAxiosParamCreator.getSmallAndLightEligibilityBySellerSKU(sellerSKU, marketplaceIds, options);
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
},
/**
* Returns the Small and Light enrollment status for the item indicated by the specified seller SKU in the specified marketplace. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 10 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace for which the enrollment status is retrieved. Note: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async getSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options) {
const localVarAxiosArgs = await localVarAxiosParamCreator.getSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options);
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
},
/**
* Returns the Small and Light fee estimates for the specified items. You must include a marketplaceId parameter to retrieve the proper fee estimates for items to be sold in that marketplace. The ordering of items in the response will mirror the order of the items in the request. Duplicate ASIN/price combinations are removed. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 3 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {SmallAndLightFeePreviewRequest} body
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async getSmallAndLightFeePreview(body, options) {
const localVarAxiosArgs = await localVarAxiosParamCreator.getSmallAndLightFeePreview(body, options);
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
},
/**
* Enrolls the item indicated by the specified seller SKU in the Small and Light program in the specified marketplace. If the item is not eligible, the ineligibility reasons are returned. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace in which to enroll the item. Note: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async putSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options) {
const localVarAxiosArgs = await localVarAxiosParamCreator.putSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options);
return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration);
},
};
};
exports.SmallAndLightApiFp = SmallAndLightApiFp;
/**
* SmallAndLightApi - factory interface
* @export
*/
const SmallAndLightApiFactory = function (configuration, basePath, axios) {
const localVarFp = (0, exports.SmallAndLightApiFp)(configuration);
return {
/**
* Removes the item indicated by the specified seller SKU from the Small and Light program in the specified marketplace. If the item is not eligible for disenrollment, the ineligibility reasons are returned. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace in which to remove the item from the Small and Light program. Note: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
deleteSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options) {
return localVarFp.deleteSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options).then((request) => request(axios, basePath));
},
/**
* Returns the Small and Light program eligibility status of the item indicated by the specified seller SKU in the specified marketplace. If the item is not eligible, the ineligibility reasons are returned. **Note:** The parameters associated with this operation may contain special characters that must be encoded to successfully call the API. To avoid errors with SKUs when encoding URLs, refer to [URL Encoding](https://developer-docs.amazon.com/sp-api/docs/url-encoding). **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 10 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace for which the eligibility status is retrieved. NOTE: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getSmallAndLightEligibilityBySellerSKU(sellerSKU, marketplaceIds, options) {
return localVarFp.getSmallAndLightEligibilityBySellerSKU(sellerSKU, marketplaceIds, options).then((request) => request(axios, basePath));
},
/**
* Returns the Small and Light enrollment status for the item indicated by the specified seller SKU in the specified marketplace. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 10 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace for which the enrollment status is retrieved. Note: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options) {
return localVarFp.getSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options).then((request) => request(axios, basePath));
},
/**
* Returns the Small and Light fee estimates for the specified items. You must include a marketplaceId parameter to retrieve the proper fee estimates for items to be sold in that marketplace. The ordering of items in the response will mirror the order of the items in the request. Duplicate ASIN/price combinations are removed. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 3 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {SmallAndLightFeePreviewRequest} body
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getSmallAndLightFeePreview(body, options) {
return localVarFp.getSmallAndLightFeePreview(body, options).then((request) => request(axios, basePath));
},
/**
* Enrolls the item indicated by the specified seller SKU in the Small and Light program in the specified marketplace. If the item is not eligible, the ineligibility reasons are returned. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {string} sellerSKU The seller SKU that identifies the item.
* @param {Array<string>} marketplaceIds The marketplace in which to enroll the item. Note: Accepts a single marketplace only.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
putSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options) {
return localVarFp.putSmallAndLightEnrollmentBySellerSKU(sellerSKU, marketplaceIds, options).then((request) => request(axios, basePath));
},
};
};
exports.SmallAndLightApiFactory = SmallAndLightApiFactory;
/**
* SmallAndLightApi - object-oriented interface
* @export
* @class SmallAndLightApi
* @extends {BaseAPI}
*/
class SmallAndLightApi extends base_1.BaseAPI {
/**
* Removes the item indicated by the specified seller SKU from the Small and Light program in the specified marketplace. If the item is not eligible for disenrollment, the ineligibility reasons are returned. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {SmallAndLightApiDeleteSmallAndLightEnrollmentBySellerSKURequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof SmallAndLightApi
*/
deleteSmallAndLightEnrollmentBySellerSKU(requestParameters, options) {
return (0, exports.SmallAndLightApiFp)(this.configuration).deleteSmallAndLightEnrollmentBySellerSKU(requestParameters.sellerSKU, requestParameters.marketplaceIds, options).then((request) => request(this.axios, this.basePath));
}
/**
* Returns the Small and Light program eligibility status of the item indicated by the specified seller SKU in the specified marketplace. If the item is not eligible, the ineligibility reasons are returned. **Note:** The parameters associated with this operation may contain special characters that must be encoded to successfully call the API. To avoid errors with SKUs when encoding URLs, refer to [URL Encoding](https://developer-docs.amazon.com/sp-api/docs/url-encoding). **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 10 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {SmallAndLightApiGetSmallAndLightEligibilityBySellerSKURequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof SmallAndLightApi
*/
getSmallAndLightEligibilityBySellerSKU(requestParameters, options) {
return (0, exports.SmallAndLightApiFp)(this.configuration).getSmallAndLightEligibilityBySellerSKU(requestParameters.sellerSKU, requestParameters.marketplaceIds, options).then((request) => request(this.axios, this.basePath));
}
/**
* Returns the Small and Light enrollment status for the item indicated by the specified seller SKU in the specified marketplace. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 10 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {SmallAndLightApiGetSmallAndLightEnrollmentBySellerSKURequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof SmallAndLightApi
*/
getSmallAndLightEnrollmentBySellerSKU(requestParameters, options) {
return (0, exports.SmallAndLightApiFp)(this.configuration).getSmallAndLightEnrollmentBySellerSKU(requestParameters.sellerSKU, requestParameters.marketplaceIds, options).then((request) => request(this.axios, this.basePath));
}
/**
* Returns the Small and Light fee estimates for the specified items. You must include a marketplaceId parameter to retrieve the proper fee estimates for items to be sold in that marketplace. The ordering of items in the response will mirror the order of the items in the request. Duplicate ASIN/price combinations are removed. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 1 | 3 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {SmallAndLightApiGetSmallAndLightFeePreviewRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof SmallAndLightApi
*/
getSmallAndLightFeePreview(requestParameters, options) {
return (0, exports.SmallAndLightApiFp)(this.configuration).getSmallAndLightFeePreview(requestParameters.body, options).then((request) => request(this.axios, this.basePath));
}
/**
* Enrolls the item indicated by the specified seller SKU in the Small and Light program in the specified marketplace. If the item is not eligible, the ineligibility reasons are returned. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 5 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, see [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
* @param {SmallAndLightApiPutSmallAndLightEnrollmentBySellerSKURequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof SmallAndLightApi
*/
putSmallAndLightEnrollmentBySellerSKU(requestParameters, options) {
return (0, exports.SmallAndLightApiFp)(this.configuration).putSmallAndLightEnrollmentBySellerSKU(requestParameters.sellerSKU, requestParameters.marketplaceIds, options).then((request) => request(this.axios, this.basePath));
}
}
exports.SmallAndLightApi = SmallAndLightApi;
//# sourceMappingURL=api.js.map