We are facing an issue with using the Enrollments API in our custom app. We have found that the pageSize parameter is not working as expected. Instead of returning only the requested number of items, all items are returned. We have raised this issue in JIRA (see: https://jira.dhis2.org/browse/DHIS2-13512).
We were wondering if there might be another method or workaround for setting the page size available?
Maybe request the totalPages separately for now? (edit: it seems that it will not work without the totalPages because it will only return the first items and there is no way to navigate?)
I hope this helps, and if it solves the issue please mark the post as solved.