Skip to content

getTotalProductCount.v1

POST
/shopgate.catalog.getTotalProductCount.v1

This pipeline will utilize the same search mechanism as the ‘getProducts_v1’ pipeline, but will omit the products and extract the totalProductCount only. This is useful in cases where the actual product data is of no interest, because it is faster. It can be combined with filters, to preview the number of products, that would be found in a filter search.

Media typeapplication/json
object
categoryId

The categoryId, but only “flat”, it will not “dive into” subcategories

string
searchPhrase

A search phrase to search for, not compatible with categoryId, use a category-filter, if you want to search inside categories

string
filters

The key is the filterId or name of filter, like categories, manufacturer or other attributes/options/properties like “Größe”. The value has to be an object with a values key, that holds an array of strings (the “id” from the filters-endpoint) or minimum and/or maximum integer values. If the filters object (from the filters-endpoint) delivers a source too, you have to send it too. For categories you have to give the content of the id property, which is the name/path of the category, not the category id itself.

object
key
additional properties
object
minimum

The minimum value for this filter, can not be combined with values.

integer format: int32
maximum

The maximum value for this filter, can not be combined with values.

integer format: int32
values
Array<string>
source

The value of the source property from the filters endpoint

string
Examplegenerated
{
"categoryId": "example",
"searchPhrase": "example",
"filters": {
"additionalProperty": {
"minimum": 1,
"maximum": 1,
"values": [
"example"
],
"source": "example"
}
}
}

Successful response.

Media typeapplication/json
object
output
required
object
totalProductCount

The number of products, that would be found when searching while using the given search parameters.

integer format: int32
Example
{
"output": {
"totalProductCount": 300
}
}

An internal error occurred.

Media typeapplication/json
object
error
required
object
code
required
string
Allowed values: EUNKNOWN
message
string
Example
{
"error": {
"code": "EUNKNOWN",
"message": "An internal error occurred."
}
}