Skip to content
Last updated

Paging and Sorting Product Lists in Norce Commerce Product Service

Overview:
This guide explains how to retrieve, page, and sort product lists using the Norce Commerce Product Service API. It details the available parameters, their effects, and the supported sorting options.

Paging

When you call the ListProduct method, the response includes:

  • ItemCount: The total number of products matching the query.
  • ProductItem list: The actual products returned for the current page.

Note: The number of products in the list may be less than ItemCount due to paging.

Paging Parameters

  • pageSize: Number of products to return per page.
  • pageNo: Page number to retrieve (default: 1).

If you request a pageNo outside the available range, the API returns an empty result.

Sorting

You can control the order of products in the result using the sort parameter. The parameter accepts a property name, optionally suffixed with Asc (ascending) or Desc (descending).

Sort Parameter Values

ValueDescription
PopularityRankSorts by a global popularity ranking, configurable per client. See Product Popularity.
NameSorts alphabetically by product name in the selected language.
PriceSorts by best price or "from price" if the product has variants.
SortOrderSorts by a manually maintained order in the admin UI (requires activation in settings).

If no sort parameter is provided, products are sorted by Name by default.

Tip: You can customize popularity ranking factors and their weighting in the admin UI.

Example Usage

  • To get the second page of 20 products, sorted by price descending:
    pageSize=20&pageNo=2&sort=Price%20Desc