@sp-api-sdk/sellers-api-v1
Version:
The Selling Partner API for Sellers (Sellers API) provides essential information about seller accounts, such as: The marketplaces a seller can list in The default language and currency of a marketplace Whether the seller has suspended listings Refer to th
1 lines • 34.9 kB
Source Map (JSON)
{"version":3,"sources":["../src/index.ts","../src/client.ts","../src/api-model/api/sellers-api.ts","../src/api-model/base.ts","../src/api-model/common.ts","../src/api-model/configuration.ts","../src/api-model/models/account.ts"],"sourcesContent":["export * from './client.js'\nexport * from './api-model/api.js'\nexport * from './api-model/models/index.js'\n","import {type ClientConfiguration, createAxiosInstance, type RateLimit} from '@sp-api-sdk/common'\n\nimport {Configuration, SellersApi} from './api-model/index.js'\n\nexport const clientRateLimits: RateLimit[] = [\n {\n method: 'get',\n // eslint-disable-next-line prefer-regex-literals\n urlRegex: new RegExp('^/sellers/v1/marketplaceParticipations$'),\n rate: 0.016,\n burst: 15,\n },\n {\n method: 'get',\n // eslint-disable-next-line prefer-regex-literals\n urlRegex: new RegExp('^/sellers/v1/account$'),\n rate: 0.016,\n burst: 15,\n },\n]\n\nexport class SellersApiClient extends SellersApi {\n constructor(configuration: ClientConfiguration) {\n const {axios, endpoint} = createAxiosInstance(configuration, clientRateLimits)\n\n super(new Configuration(), endpoint, axios)\n }\n}\n","/* tslint:disable */\n/* eslint-disable */\n/**\n * The Selling Partner API for Sellers\n * The [Selling Partner API for Sellers](https://developer-docs.amazon.com/sp-api/docs/sellers-api-v1-reference) (Sellers API) provides essential information about seller accounts, such as: - The marketplaces a seller can list in - The default language and currency of a marketplace - Whether the seller has suspended listings Refer to the [Sellers API reference](https://developer-docs.amazon.com/sp-api/docs/sellers-api-v1-reference) for details about this API\\'s operations, data types, and schemas.\n *\n * The version of the OpenAPI document: v1\n * \n *\n * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).\n * https://openapi-generator.tech\n * Do not edit the class manually.\n */\n\n\nimport type { Configuration } from '../configuration.js';\nimport type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';\nimport globalAxios from 'axios';\n// Some imports not used depending on template conditions\n// @ts-ignore\nimport { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction, replaceWithSerializableTypeIfNeeded } from '../common.js';\n// @ts-ignore\nimport { BASE_PATH, COLLECTION_FORMATS, type RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base.js';\n// @ts-ignore\nimport type { GetAccountResponse } from '../models/index.js';\n// @ts-ignore\nimport type { GetMarketplaceParticipationsResponse } from '../models/index.js';\n/**\n * SellersApi - axios parameter creator\n */\nexport const SellersApiAxiosParamCreator = function (configuration?: Configuration) {\n return {\n /**\n * Returns information about a seller account and its marketplaces. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 0.016 | 15 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).\n * @param {*} [options] Override http request option.\n * @throws {RequiredError}\n */\n getAccount: async (options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {\n const localVarPath = `/sellers/v1/account`;\n // use dummy base URL string because the URL constructor only accepts absolute URLs.\n const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);\n let baseOptions;\n if (configuration) {\n baseOptions = configuration.baseOptions;\n }\n\n const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};\n const localVarHeaderParameter = {} as any;\n const localVarQueryParameter = {} as any;\n\n localVarHeaderParameter['Accept'] = 'application/json';\n\n setSearchParams(localVarUrlObj, localVarQueryParameter);\n let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};\n localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};\n\n return {\n url: toPathString(localVarUrlObj),\n options: localVarRequestOptions,\n };\n },\n /**\n * Returns a list of marketplaces where the seller can list items and information about the seller\\'s participation in those marketplaces. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 0.016 | 15 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).\n * @param {*} [options] Override http request option.\n * @throws {RequiredError}\n */\n getMarketplaceParticipations: async (options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {\n const localVarPath = `/sellers/v1/marketplaceParticipations`;\n // use dummy base URL string because the URL constructor only accepts absolute URLs.\n const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);\n let baseOptions;\n if (configuration) {\n baseOptions = configuration.baseOptions;\n }\n\n const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};\n const localVarHeaderParameter = {} as any;\n const localVarQueryParameter = {} as any;\n\n localVarHeaderParameter['Accept'] = 'application/json,payload';\n\n setSearchParams(localVarUrlObj, localVarQueryParameter);\n let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};\n localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};\n\n return {\n url: toPathString(localVarUrlObj),\n options: localVarRequestOptions,\n };\n },\n }\n};\n\n/**\n * SellersApi - functional programming interface\n */\nexport const SellersApiFp = function(configuration?: Configuration) {\n const localVarAxiosParamCreator = SellersApiAxiosParamCreator(configuration)\n return {\n /**\n * Returns information about a seller account and its marketplaces. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 0.016 | 15 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).\n * @param {*} [options] Override http request option.\n * @throws {RequiredError}\n */\n async getAccount(options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetAccountResponse>> {\n const localVarAxiosArgs = await localVarAxiosParamCreator.getAccount(options);\n const localVarOperationServerIndex = configuration?.serverIndex ?? 0;\n const localVarOperationServerBasePath = operationServerMap['SellersApi.getAccount']?.[localVarOperationServerIndex]?.url;\n return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);\n },\n /**\n * Returns a list of marketplaces where the seller can list items and information about the seller\\'s participation in those marketplaces. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 0.016 | 15 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).\n * @param {*} [options] Override http request option.\n * @throws {RequiredError}\n */\n async getMarketplaceParticipations(options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetMarketplaceParticipationsResponse>> {\n const localVarAxiosArgs = await localVarAxiosParamCreator.getMarketplaceParticipations(options);\n const localVarOperationServerIndex = configuration?.serverIndex ?? 0;\n const localVarOperationServerBasePath = operationServerMap['SellersApi.getMarketplaceParticipations']?.[localVarOperationServerIndex]?.url;\n return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);\n },\n }\n};\n\n/**\n * SellersApi - factory interface\n */\nexport const SellersApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {\n const localVarFp = SellersApiFp(configuration)\n return {\n /**\n * Returns information about a seller account and its marketplaces. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 0.016 | 15 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).\n * @param {*} [options] Override http request option.\n * @throws {RequiredError}\n */\n getAccount(options?: RawAxiosRequestConfig): AxiosPromise<GetAccountResponse> {\n return localVarFp.getAccount(options).then((request) => request(axios, basePath));\n },\n /**\n * Returns a list of marketplaces where the seller can list items and information about the seller\\'s participation in those marketplaces. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 0.016 | 15 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).\n * @param {*} [options] Override http request option.\n * @throws {RequiredError}\n */\n getMarketplaceParticipations(options?: RawAxiosRequestConfig): AxiosPromise<GetMarketplaceParticipationsResponse> {\n return localVarFp.getMarketplaceParticipations(options).then((request) => request(axios, basePath));\n },\n };\n};\n\n/**\n * SellersApi - object-oriented interface\n */\nexport class SellersApi extends BaseAPI {\n /**\n * Returns information about a seller account and its marketplaces. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 0.016 | 15 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).\n * @param {*} [options] Override http request option.\n * @throws {RequiredError}\n */\n public getAccount(options?: RawAxiosRequestConfig) {\n return SellersApiFp(this.configuration).getAccount(options).then((request) => request(this.axios, this.basePath));\n }\n\n /**\n * Returns a list of marketplaces where the seller can list items and information about the seller\\'s participation in those marketplaces. **Usage Plan:** | Rate (requests per second) | Burst | | ---- | ---- | | 0.016 | 15 | The `x-amzn-RateLimit-Limit` response header returns the usage plan rate limits that were applied to the requested operation, when available. The preceding table indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may have higher rate and burst values than those shown here. For more information, refer to [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).\n * @param {*} [options] Override http request option.\n * @throws {RequiredError}\n */\n public getMarketplaceParticipations(options?: RawAxiosRequestConfig) {\n return SellersApiFp(this.configuration).getMarketplaceParticipations(options).then((request) => request(this.axios, this.basePath));\n }\n}\n\n","/* tslint:disable */\n/* eslint-disable */\n/**\n * The Selling Partner API for Sellers\n * The [Selling Partner API for Sellers](https://developer-docs.amazon.com/sp-api/docs/sellers-api-v1-reference) (Sellers API) provides essential information about seller accounts, such as: - The marketplaces a seller can list in - The default language and currency of a marketplace - Whether the seller has suspended listings Refer to the [Sellers API reference](https://developer-docs.amazon.com/sp-api/docs/sellers-api-v1-reference) for details about this API\\'s operations, data types, and schemas.\n *\n * The version of the OpenAPI document: v1\n * \n *\n * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).\n * https://openapi-generator.tech\n * Do not edit the class manually.\n */\n\n\nimport type { Configuration } from './configuration.js';\n// Some imports not used depending on template conditions\n// @ts-ignore\nimport type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';\nimport globalAxios from 'axios';\n\nexport const BASE_PATH = \"https://sellingpartnerapi-na.amazon.com\".replace(/\\/+$/, \"\");\n\nexport const COLLECTION_FORMATS = {\n csv: \",\",\n ssv: \" \",\n tsv: \"\\t\",\n pipes: \"|\",\n};\n\nexport interface RequestArgs {\n url: string;\n options: RawAxiosRequestConfig;\n}\n\nexport class BaseAPI {\n protected configuration: Configuration | undefined;\n\n constructor(configuration?: Configuration, protected basePath: string = BASE_PATH, protected axios: AxiosInstance = globalAxios) {\n if (configuration) {\n this.configuration = configuration;\n this.basePath = configuration.basePath ?? basePath;\n }\n }\n};\n\nexport class RequiredError extends Error {\n constructor(public field: string, msg?: string) {\n super(msg);\n this.name = \"RequiredError\"\n }\n}\n\ninterface ServerMap {\n [key: string]: {\n url: string,\n description: string,\n }[];\n}\n\nexport const operationServerMap: ServerMap = {\n}\n","/* tslint:disable */\n/* eslint-disable */\n/**\n * The Selling Partner API for Sellers\n * The [Selling Partner API for Sellers](https://developer-docs.amazon.com/sp-api/docs/sellers-api-v1-reference) (Sellers API) provides essential information about seller accounts, such as: - The marketplaces a seller can list in - The default language and currency of a marketplace - Whether the seller has suspended listings Refer to the [Sellers API reference](https://developer-docs.amazon.com/sp-api/docs/sellers-api-v1-reference) for details about this API\\'s operations, data types, and schemas.\n *\n * The version of the OpenAPI document: v1\n * \n *\n * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).\n * https://openapi-generator.tech\n * Do not edit the class manually.\n */\n\nimport type { Configuration } from \"./configuration.js\";\nimport type { RequestArgs } from \"./base.js\";\nimport type { AxiosInstance, AxiosResponse } from 'axios';\nimport { RequiredError } from \"./base.js\";\n\nexport const DUMMY_BASE_URL = 'https://example.com'\n\n/**\n *\n * @throws {RequiredError}\n */\nexport const assertParamExists = function (functionName: string, paramName: string, paramValue: unknown) {\n if (paramValue === null || paramValue === undefined) {\n throw new RequiredError(paramName, `Required parameter ${paramName} was null or undefined when calling ${functionName}.`);\n }\n}\n\nexport const setApiKeyToObject = async function (object: any, keyParamName: string, configuration?: Configuration) {\n if (configuration && configuration.apiKey) {\n const localVarApiKeyValue = typeof configuration.apiKey === 'function'\n ? await configuration.apiKey(keyParamName)\n : await configuration.apiKey;\n object[keyParamName] = localVarApiKeyValue;\n }\n}\n\nexport const setBasicAuthToObject = function (object: any, configuration?: Configuration) {\n if (configuration && (configuration.username || configuration.password)) {\n object[\"auth\"] = { username: configuration.username, password: configuration.password };\n }\n}\n\nexport const setBearerAuthToObject = async function (object: any, configuration?: Configuration) {\n if (configuration && configuration.accessToken) {\n const accessToken = typeof configuration.accessToken === 'function'\n ? await configuration.accessToken()\n : await configuration.accessToken;\n object[\"Authorization\"] = \"Bearer \" + accessToken;\n }\n}\n\nexport const setOAuthToObject = async function (object: any, name: string, scopes: string[], configuration?: Configuration) {\n if (configuration && configuration.accessToken) {\n const localVarAccessTokenValue = typeof configuration.accessToken === 'function'\n ? await configuration.accessToken(name, scopes)\n : await configuration.accessToken;\n object[\"Authorization\"] = \"Bearer \" + localVarAccessTokenValue;\n }\n}\n\n\nfunction setFlattenedQueryParams(urlSearchParams: URLSearchParams, parameter: any, key: string = \"\"): void {\n if (parameter == null) return;\n if (typeof parameter === \"object\") {\n if (Array.isArray(parameter) || parameter instanceof Set) {\n (parameter as any[]).forEach(item => setFlattenedQueryParams(urlSearchParams, item, key));\n }\n else {\n Object.keys(parameter).forEach(currentKey =>\n setFlattenedQueryParams(urlSearchParams, parameter[currentKey], `${key}${key !== '' ? '.' : ''}${currentKey}`)\n );\n }\n }\n else {\n if (urlSearchParams.has(key)) {\n urlSearchParams.append(key, parameter);\n }\n else {\n urlSearchParams.set(key, parameter);\n }\n }\n}\n\nexport const setSearchParams = function (url: URL, ...objects: any[]) {\n const searchParams = new URLSearchParams(url.search);\n setFlattenedQueryParams(searchParams, objects);\n url.search = searchParams.toString();\n}\n\n/**\n * JSON serialization helper function which replaces instances of unserializable types with serializable ones.\n * This function will run for every key-value pair encountered by JSON.stringify while traversing an object.\n * Converting a set to a string will return an empty object, so an intermediate conversion to an array is required.\n */\n// @ts-ignore\nexport const replaceWithSerializableTypeIfNeeded = function(key: string, value: any) {\n if (value instanceof Set) {\n return Array.from(value);\n } else {\n return value;\n }\n}\n\nexport const serializeDataIfNeeded = function (value: any, requestOptions: any, configuration?: Configuration) {\n const nonString = typeof value !== 'string';\n const needsSerialization = nonString && configuration && configuration.isJsonMime\n ? configuration.isJsonMime(requestOptions.headers['Content-Type'])\n : nonString;\n return needsSerialization\n ? JSON.stringify(value !== undefined ? value : {}, replaceWithSerializableTypeIfNeeded)\n : (value || \"\");\n}\n\nexport const toPathString = function (url: URL) {\n return url.pathname + url.search + url.hash\n}\n\nexport const createRequestFunction = function (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) {\n return <T = unknown, R = AxiosResponse<T>>(axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {\n const axiosRequestArgs = {...axiosArgs.options, url: (axios.defaults.baseURL ? '' : configuration?.basePath ?? basePath) + axiosArgs.url};\n return axios.request<T, R>(axiosRequestArgs);\n };\n}\n","/* tslint:disable */\n/**\n * The Selling Partner API for Sellers\n * The [Selling Partner API for Sellers](https://developer-docs.amazon.com/sp-api/docs/sellers-api-v1-reference) (Sellers API) provides essential information about seller accounts, such as: - The marketplaces a seller can list in - The default language and currency of a marketplace - Whether the seller has suspended listings Refer to the [Sellers API reference](https://developer-docs.amazon.com/sp-api/docs/sellers-api-v1-reference) for details about this API\\'s operations, data types, and schemas.\n *\n * The version of the OpenAPI document: v1\n * \n *\n * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).\n * https://openapi-generator.tech\n * Do not edit the class manually.\n */\n\ninterface AWSv4Configuration {\n options?: {\n region?: string\n service?: string\n }\n credentials?: {\n accessKeyId?: string\n secretAccessKey?: string,\n sessionToken?: string\n }\n}\n\nexport interface ConfigurationParameters {\n apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);\n username?: string;\n password?: string;\n accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise<string>);\n awsv4?: AWSv4Configuration;\n basePath?: string;\n serverIndex?: number;\n baseOptions?: any;\n formDataCtor?: new () => any;\n}\n\nexport class Configuration {\n /**\n * parameter for apiKey security\n * @param name security name\n */\n apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);\n /**\n * parameter for basic security\n */\n username?: string;\n /**\n * parameter for basic security\n */\n password?: string;\n /**\n * parameter for oauth2 security\n * @param name security name\n * @param scopes oauth2 scope\n */\n accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise<string>);\n /**\n * parameter for aws4 signature security\n * @param {Object} AWS4Signature - AWS4 Signature security\n * @param {string} options.region - aws region\n * @param {string} options.service - name of the service.\n * @param {string} credentials.accessKeyId - aws access key id\n * @param {string} credentials.secretAccessKey - aws access key\n * @param {string} credentials.sessionToken - aws session token\n * @memberof Configuration\n */\n awsv4?: AWSv4Configuration;\n /**\n * override base path\n */\n basePath?: string;\n /**\n * override server index\n */\n serverIndex?: number;\n /**\n * base options for axios calls\n */\n baseOptions?: any;\n /**\n * The FormData constructor that will be used to create multipart form data\n * requests. You can inject this here so that execution environments that\n * do not support the FormData class can still run the generated client.\n *\n * @type {new () => FormData}\n */\n formDataCtor?: new () => any;\n\n constructor(param: ConfigurationParameters = {}) {\n this.apiKey = param.apiKey;\n this.username = param.username;\n this.password = param.password;\n this.accessToken = param.accessToken;\n this.awsv4 = param.awsv4;\n this.basePath = param.basePath;\n this.serverIndex = param.serverIndex;\n this.baseOptions = {\n ...param.baseOptions,\n headers: {\n ...param.baseOptions?.headers,\n },\n };\n this.formDataCtor = param.formDataCtor;\n }\n\n /**\n * Check if the given MIME is a JSON MIME.\n * JSON MIME examples:\n * application/json\n * application/json; charset=UTF8\n * APPLICATION/JSON\n * application/vnd.company+json\n * @param mime - MIME (Multipurpose Internet Mail Extensions)\n * @return True if the given MIME is JSON, false otherwise.\n */\n public isJsonMime(mime: string): boolean {\n const jsonMime: RegExp = /^(application\\/json|[^;/ \\t]+\\/[^;/ \\t]+[+]json)[ \\t]*(;.*)?$/i;\n return mime !== null && jsonMime.test(mime);\n }\n}\n","/* tslint:disable */\n/* eslint-disable */\n/**\n * The Selling Partner API for Sellers\n * The [Selling Partner API for Sellers](https://developer-docs.amazon.com/sp-api/docs/sellers-api-v1-reference) (Sellers API) provides essential information about seller accounts, such as: - The marketplaces a seller can list in - The default language and currency of a marketplace - Whether the seller has suspended listings Refer to the [Sellers API reference](https://developer-docs.amazon.com/sp-api/docs/sellers-api-v1-reference) for details about this API\\'s operations, data types, and schemas.\n *\n * The version of the OpenAPI document: v1\n * \n *\n * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).\n * https://openapi-generator.tech\n * Do not edit the class manually.\n */\n\n\n// May contain unused imports in some cases\n// @ts-ignore\nimport type { Business } from './business.js';\n// May contain unused imports in some cases\n// @ts-ignore\nimport type { MarketplaceParticipation } from './marketplace-participation.js';\n// May contain unused imports in some cases\n// @ts-ignore\nimport type { PrimaryContact } from './primary-contact.js';\n\n/**\n * The response schema for the `getAccount` operation.\n */\nexport interface Account {\n /**\n * List of marketplace participations.\n */\n 'marketplaceParticipationList': Array<MarketplaceParticipation>;\n /**\n * The type of business registered for the seller account.\n */\n 'businessType': AccountBusinessTypeEnum;\n /**\n * The selling plan details.\n */\n 'sellingPlan': AccountSellingPlanEnum;\n 'business'?: Business;\n 'primaryContact'?: PrimaryContact;\n}\n\nexport const AccountBusinessTypeEnum = {\n Charity: 'CHARITY',\n Craftsman: 'CRAFTSMAN',\n NaturalPersonCompany: 'NATURAL_PERSON_COMPANY',\n PublicListed: 'PUBLIC_LISTED',\n PrivateLimited: 'PRIVATE_LIMITED',\n SoleProprietorship: 'SOLE_PROPRIETORSHIP',\n StateOwned: 'STATE_OWNED',\n Individual: 'INDIVIDUAL',\n} as const;\n\nexport type AccountBusinessTypeEnum = typeof AccountBusinessTypeEnum[keyof typeof AccountBusinessTypeEnum];\nexport const AccountSellingPlanEnum = {\n Professional: 'PROFESSIONAL',\n Individual: 'INDIVIDUAL',\n} as const;\n\nexport type AccountSellingPlanEnum = typeof AccountSellingPlanEnum[keyof typeof AccountSellingPlanEnum];\n\n\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,iBAA4E;;;ACiB5E,IAAAC,gBAAwB;;;ACExB,mBAAwB;AAEjB,IAAM,YAAY,0CAA0C,QAAQ,QAAQ,EAAE;AAc9E,IAAM,UAAN,MAAc;AAAA,EAGjB,YAAY,eAAyC,WAAmB,WAAqB,QAAuB,aAAAC,SAAa;AAA5E;AAAwC;AACzF,QAAI,eAAe;AACf,WAAK,gBAAgB;AACrB,WAAK,WAAW,cAAc,YAAY;AAAA,IAC9C;AAAA,EACJ;AAAA,EALqD;AAAA,EAAwC;AAAA,EAFnF;AAQd;AAgBO,IAAM,qBAAgC,CAC7C;;;AC1CO,IAAM,iBAAiB;AA8C9B,SAAS,wBAAwB,iBAAkC,WAAgB,MAAc,IAAU;AACvG,MAAI,aAAa,KAAM;AACvB,MAAI,OAAO,cAAc,UAAU;AAC/B,QAAI,MAAM,QAAQ,SAAS,KAAK,qBAAqB,KAAK;AACtD,MAAC,UAAoB,QAAQ,UAAQ,wBAAwB,iBAAiB,MAAM,GAAG,CAAC;AAAA,IAC5F,OACK;AACD,aAAO,KAAK,SAAS,EAAE;AAAA,QAAQ,gBAC3B,wBAAwB,iBAAiB,UAAU,UAAU,GAAG,GAAG,GAAG,GAAG,QAAQ,KAAK,MAAM,EAAE,GAAG,UAAU,EAAE;AAAA,MACjH;AAAA,IACJ;AAAA,EACJ,OACK;AACD,QAAI,gBAAgB,IAAI,GAAG,GAAG;AAC1B,sBAAgB,OAAO,KAAK,SAAS;AAAA,IACzC,OACK;AACD,sBAAgB,IAAI,KAAK,SAAS;AAAA,IACtC;A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