Retrieve all product mappings

Retrieve all product category mappings using the Smart Categorization API.

Learn how to retrieve paginated product mappings for a client, including filtering, sorting, and field projection.

Endpoint

POST /public-api/allproduct/all-product-mappings

Returns a paginated list of all product mappings for the specified client. Supports filtering, sorting, free-text search, and column projection.

Authentication

All requests require a valid bearer token in the Authorization header.

Authorization: Bearer {ACCESS_TOKEN}

Request

{
  "clientId": 42,
  "recordsPerPage": 25,
  "sortField": "modifiedDate",
  "sortDirection": "desc",
  "selectedColumns": [
    "productId",
    "productName",
    "category",
    "status"
  ]
}
PropertyTypeRequiredDescription
clientIdintegerYesThe numeric identifier of the client whose products are being requested.
cursorstringNoOpaque pagination cursor returned from the previous response.
recordsPerPageintegerNoNumber of products to return per page. Default is 10.
sortFieldstringNoProduct field name to sort results by.
sortDirectionstringNoSorting direction: asc or desc.
searchValuestringNoFree-text search value.
filtersarrayNoFilter conditions to apply.
selectedColumnsarrayNoOptional list of fields to include in the response.
selectedIdsarrayNoOptional list of product IDs to restrict the response to.

Example

curl --request POST \
  --url https://smartcategorization.vertexcloud.com/public-api/allproduct/all-product-mappings \
  --header "Authorization: Bearer {ACCESS_TOKEN}" \
  --header "Content-Type: application/json" \
  --data '{
    "clientId": 42,
    "recordsPerPage": 25,
    "sortField": "modifiedDate",
    "sortDirection": "desc",
    "selectedColumns": [
      "productId",
      "productName",
      "category",
      "status"
    ]
  }'

Response

{
  "cursor": "eyJwYWdlIjoyfQ==",
  "recordCount": 128,
  "productItems": [
    {
      "productId": "P-1001",
      "productName": "Wireless Mouse",
      "category": "Computer Accessories",
      "status": "approved"
    }
  ]
}

Errors

StatusDescription
400 Bad RequestThe request is invalid. Common reasons include an invalid filter field, unsupported filter operation, or malformed request body.
401 UnauthorizedThe bearer token is missing, expired, or invalid.
403 ForbiddenThe caller does not have access to the specified client.
404 Not FoundNo products are found for the client and filter criteria.
500 Internal Server ErrorThe service encountered an unexpected error while processing the request.

Did this page help you?