The page parameter for /products endpoint has no observable effect on pagination
Prerequisites
- I understand and accept the project's code of conduct.
- I have already searched in existing issues and found no previous report of this bug.
Describe the bug and add attachments
The /products endpoint documents a page parameter in the Back Office API documentation (/configure/advanced/admin-api/docs.html), but changing its value does not change the products returned by the endpoint.
The issue is reproducible in both Postman and the Back Office API documentation interface. For example, with 33 products in total, the following requests return the same products when limit=3:
GET /products?page=1&limit=3
GET /products?page=2&limit=3
The response reports limit: 3, but both requests return products with IDs 1, 2, and 3.
Steps to reproduce
- Send a GET request to
/products?page=1&limit=3. - Record the returned product IDs.
- Send a GET request to
/products?page=2&limit=3. - Compare the returned product IDs.
Expected behavior
Changing the page parameter should return the corresponding page of products. For example, with limit=3, page 2 should return a different set of products from page 1.
Actual Result
Both requests return the same products (product IDs 1, 2, and 3). Changing the page parameter has no observable effect on the returned page of products.
PrestaShop version where the bug happens
9.2.0
How have you installed PrestaShop
Docker Image
PHP version(s) where the bug happened
8.5
Your company or customer's name goes here (if applicable).
No response
Source: PrestaShop/PrestaShop