Home > @vsf-enterprise/sap-commerce-webservices-sdk > ProductsApi

ProductsApi class

ProductsApi - object-oriented interface ProductsApi {BaseAPI}

Signature:

export declare class ProductsApi extends BaseAPI 

Extends: BaseAPI

Methods

Method Modifiers Description
countProducts(baseSiteId, query, options) In the response header, the "x-total-count" indicates the total number of products satisfying a query. Get a header with total number of products.
countProductStockByLocation(baseSiteId, productCode, latitude, location, longitude, options) In the response header, the "x-total-count" indicates the total number of a product's stock levels. The following two sets of parameters are available: location (required); or longitude (required), and latitude (required). Get header with a total number of product's stock levels.
createProductReview(baseSiteId, productCode, review, fields, options) Creates a new customer review as an anonymous user. Creates a new customer review as an anonymous user.
getExpressUpdateProducts(baseSiteId, timestamp, catalog, fields, options) Returns products added to the express update feed. Returns only elements updated after the provided timestamp. The queue is cleared using a defined cronjob. Get products added to the express update feed.
getLocationProductStock(baseSiteId, productCode, currentPage, fields, latitude, location, longitude, pageSize, options) Returns a product's stock levels sorted by distance from the specified location, which is provided using the free-text "location" parameter, or by using the longitude and latitude parameters. The following two sets of parameters are available: location (required), currentPage (optional), pageSize (optional); or longitude (required), latitude (required), currentPage (optional), pageSize(optional). Get a product's stock level.
getProduct(baseSiteId, productCode, fields, options) Returns details of a single product according to a product code. Get product details.
getProductReferences(baseSiteId, productCode, fields, pageSize, referenceType, options) Returns references for a product with a given product code. Reference type specifies which references to return. Get a product reference
getProductReviews(baseSiteId, productCode, fields, maxCount, options) Returns the reviews for a product with a given product code. Get reviews for a product
getProducts(baseSiteId, currentPage, fields, pageSize, query, searchQueryContext, sort, options) Returns a list of products and additional data, such as available facets, available sorting, and pagination options. It can also include spelling suggestions. To make spelling suggestions work, you need to make sure that "enableSpellCheck" on the SearchQuery is set to "true" (by default, it should already be set to "true"). You also need to have indexed properties configured to be used for spellchecking. Get a list of products and additional data
getStoreProductStock(baseSiteId, productCode, storeName, fields, options) Returns a product's stock level for a particular store (in other words, for a particular point of sale). Get a product's stock level for a store
getSuggestions(baseSiteId, term, fields, max, options) Returns a list of all available suggestions related to a given term and limits the results to a specific value of the max parameter. Get a list of available suggestions