import { Amazon } from "./amazon.type"; export declare namespace AmazonProducts { export type IdType = "ASIN" | "GCID" | "SellerSKU" | "UPC" | "EAN" | "ISBN" | "JAN"; export interface ASINProductResponse { ASIN: string; status: "Success"; products: { product: T; }; } export interface SKUProductResponse { SellerSKU: string; status: "Success"; products: { product: T; }; } export interface BaseProductErrorResponse { asin: string; status: "ClientError"; error: { type: "Sender"; code: "InvalidParameterValue"; message: string; }; } export interface ListMatchingProductsParams { marketplaceId: Amazon.Marketplace; query: string; queryContextId: string; } export type ListMatchingProductsResponse = ASINProductResponse<{}> | BaseProductErrorResponse; export interface GetMatchingProductParams { marketplaceId: Amazon.Marketplace; ASINList: string[]; } export type GetMatchingProductResponse = ASINProductResponse<{ identifiers: Identifiers; attributeSets?: AttributeSets; relationships?: Relationships; salesRankings?: SalesRankings; }> | BaseProductErrorResponse; export interface GetMatchingProductForIdParams { marketplaceId: Amazon.Marketplace; idList: string[]; idType: IdType; } export type GetMatchingProductForIdResponse = { id: string; idType: IdType; status: "Success"; products: { product: { identifiers: Identifiers; attributeSets?: AttributeSets; relationships?: Relationships; salesRankings?: SalesRankings; }; }; } | BaseProductErrorResponse; export interface GetCompetitivePricingForSKUParams { marketplaceId: Amazon.Marketplace; sellerSKUList: string[]; } export type GetCompetitivePricingForSKUResponse = SKUProductResponse<{ identifiers: IdentifiersWithSku; competitivePricing?: CompetitivePricing; salesRankings?: SalesRankings; }> | BaseProductErrorResponse; export interface GetCompetitivePricingForASINParams { marketplaceId: Amazon.Marketplace; ASINList: string[]; } export type GetCompetitivePricingForASINResponse = ASINProductResponse<{ identifiers: Identifiers; competitivePricing?: CompetitivePricing; salesRankings?: SalesRankings; }> | BaseProductErrorResponse; export interface GetLowestOfferListingsForSKUParams { marketplaceId: Amazon.Marketplace; sellerSKUList: string[]; itemCondition?: Amazon.ListingCondition; } export type GetLowestOfferListingsForSKUResponse = SKUProductResponse<{ identifiers: IdentifiersWithSku; lowestOfferListings?: LowestOfferListings; }> | BaseProductErrorResponse; export interface GetLowestOfferListingsForASINParams { marketplaceId: Amazon.Marketplace; ASINList: string[]; itemCondition?: Amazon.ListingCondition; } export type GetLowestOfferListingsForASINResponse = ASINProductResponse<{ identifiers: Identifiers; lowestOfferListings: LowestOfferListings; }> | BaseProductErrorResponse; export interface GetLowestPricedOffersForSKUParams { marketplaceId: Amazon.Marketplace; sellerSKU: string; itemCondition: Amazon.ListingCondition; } export type GetLowestPricedOffersForSKUResponse = { MarketplaceID: "ATVPDKIKX0DER"; SKU: "8Q-EJB2-SMLL"; ItemCondition: "New"; status: "Success"; identifier: { marketplaceId: "ATVPDKIKX0DER"; sellerSku: "8Q-EJB2-SMLL"; itemCondition: "New"; }; summary?: Summary; offers?: LowestPricedOffers; } | BaseProductErrorResponse; export interface GetLowestPricedOffersForASINParams { marketplaceId: Amazon.Marketplace; ASIN: string; itemCondition: Amazon.ListingCondition; } export type GetLowestPricedOffersForASINResponse = { MarketplaceID: "ATVPDKIKX0DER"; ItemCondition: "New"; ASIN: "B07JFSSPS1"; status: "Success"; identifier: { marketplaceId: "ATVPDKIKX0DER"; asin: "8Q-EJB2-SMLL"; itemCondition: "New"; }; summary?: Summary; offers?: LowestPricedOffers; } | BaseProductErrorResponse; export interface GetMyFeesEstimateParams { feesEstimateRequestList: FeesEstimateRequestList[]; } export type GetMyFeesEstimateResponse = ASINProductResponse<{}> | BaseProductErrorResponse; export interface GetMyPriceForSKUParams { marketplaceId: Amazon.Marketplace; sellerSKUList: string[]; itemCondition?: Amazon.ListingCondition; } export type GetMyPriceForSKUResponse = SKUProductResponse<{ identifiers: Identifiers; offers?: MyPriceOffers; }> | BaseProductErrorResponse; export interface GetMyPriceForASINParams { marketplaceId: Amazon.Marketplace; ASINList: string[]; itemCondition?: Amazon.ListingCondition; } export type GetMyPriceForASINResponse = ASINProductResponse<{ identifiers: Identifiers; offers?: MyPriceOffers; }> | BaseProductErrorResponse; export interface GetProductCategoriesForSKUParams { marketplaceId: Amazon.Marketplace; sellerSKU: string; } export type GetProductCategoriesForSKUResponse = SKUProductResponse<{}> | BaseProductErrorResponse; export interface GetProductCategoriesForASINParams { marketplaceId: Amazon.Marketplace; ASIN: string; } export type GetProductCategoriesForASINResponse = ASINProductResponse<{}> | BaseProductErrorResponse; export interface FeesEstimateRequestList { marketplaceId: Amazon.Marketplace; idType: "ASIN" | "SellerSKU"; idValue: string; priceToEstimateFees: PriceToEstimateFees; identifier: string; isAmazonFulfilled: Amazon.BooleanType; } export interface PriceToEstimateFees { listingPrice: Amazon.Money; shipping?: Amazon.Money; points?: Amazon.Points; } interface SalesRankings { salesRank: SalesRank[]; } interface SalesRank { productCategoryId: string; rank: string; } interface AttributeSets { itemAttributes: ItemAttributes; } interface ItemAttributes { lang?: string; binding?: string; brand?: string; itemDimensions?: Dimensions; label?: string; listPrice?: ListPrice; manufacturer?: string; model?: string; packageDimensions?: Dimensions; partNumber?: string; processorCount?: string; productGroup?: string; productTypeName?: string; publisher?: string; smallImage?: SmallImage; studio?: string; title?: string; [key: string]: any; } interface SmallImage { url: string; height: CommonAttribute; width: CommonAttribute; } interface ListPrice { amount: string; currencyCode: string; } interface Dimensions { height?: CommonAttribute; length?: CommonAttribute; width?: CommonAttribute; weight?: CommonAttribute; } interface CommonAttribute { value: string; units: string; } interface MarketplaceAsin { marketplaceId: string; asin: string; } interface Identifiers { marketplaceAsin: MarketplaceAsin; } interface IdentifiersWithSku extends Identifiers { skuIdentifier: SkuIdentifier; } interface SkuIdentifier { marketplaceId: string; sellerId: string; sellerSku: string; } interface Relationships { variationParent?: VariationParent; variationChild?: VariationChild[]; } interface VariationParent { identifiers: Identifiers; } interface VariationChild { identifiers: Identifiers; [key: string]: any; } interface CompetitivePricing { competitivePrices: CompetitivePrices; numberOfOfferListings: NumberOfOfferListings; } interface NumberOfOfferListings { offerListingCount: OfferListingCount[]; } interface OfferListingCount { value: string; condition: string; } interface CompetitivePrices { competitivePrice: CompetitivePrice[]; } interface CompetitivePrice { belongsToRequester: boolean; condition: string; subcondition: string; competitivePriceId: string; price: Price; } interface Price { landedPrice: LandedPrice; listingPrice: LandedPrice; shipping: LandedPrice; } interface LandedPrice { currencyCode: string; amount: string; } interface LowestOfferListings { lowestOfferListing: LowestOfferListing[]; } interface LowestOfferListing { qualifiers: Qualifiers; numberOfOfferListingsConsidered: string; sellerFeedbackCount: string; price: Price; multipleOffersAtLowestPrice: string; } interface Qualifiers { itemCondition: Amazon.ListingCondition; itemSubcondition: string; fulfillmentChannel: "Amazon" | "Merchant"; shipsDomestically: "True" | "False"; shippingTime: ShippingTime; sellerPositiveFeedbackRating: string; } interface ShippingTime { max: string; } interface LowestPricedOffers { offer: LowestPricedOffer[]; } interface LowestPricedOffer { myOffer: Amazon.BooleanType; subCondition: string; sellerFeedbackRating: SellerFeedbackRating; shippingTime: ShippingTime; listingPrice: LandedPrice; shipping: LandedPrice; shipsFrom: ShipsFrom; isFulfilledByAmazon: Amazon.BooleanType; isBuyBoxWinner: Amazon.BooleanType; isFeaturedMerchant: Amazon.BooleanType; } interface ShipsFrom { country: string; } interface ShippingTime { minimumHours: string; maximumHours: string; availabilityType: string; } interface SellerFeedbackRating { sellerPositiveFeedbackRating: string; feedbackCount: string; } interface Summary { totalOfferCount: string; numberOfOffers: NumberOfOffers; lowestPrices: LowestPrices; buyBoxPrices: BuyBoxPrices; listPrice: undefined; buyBoxEligibleOffers: NumberOfOffers; } interface BuyBoxPrices { buyBoxPrice: BuyBoxPrice[]; } interface BuyBoxPrice { condition: string; landedPrice: LandedPrice; listingPrice: LandedPrice; shipping: LandedPrice; } interface LowestPrices { lowestPrice: LowestPrice[]; } interface LowestPrice { condition: string; fulfillmentChannel: string; landedPrice: LandedPrice; listingPrice: LandedPrice; shipping: LandedPrice; } interface NumberOfOffers { offerCount: OfferCount[]; } interface OfferCount { value: string; condition: string; fulfillmentChannel: "Amazon" | "Merchant"; } interface MyPriceOffers { offer: MyPriceOffer[]; } interface MyPriceOffer { buyingPrice: BuyingPrice; regularPrice: LandedPrice; fulfillmentChannel: "AMAZON" | "MERCHANT"; itemCondition: Amazon.ListingCondition; itemSubCondition: Amazon.ListingCondition; sellerId: string; sellerSku: string; } interface BuyingPrice { landedPrice: LandedPrice; listingPrice: LandedPrice; shipping: LandedPrice; } export {}; }