Per the strapi documentation, the way to filter a collection is to use a square bracket syntax in the request query, eg
GET /api/users?filters[username][$eq]=John
In the first instance when implementing this in my PHP application, I reached for the mbvienasbaitas/strapi-php-client library which is linked from the strapi site. This however relies on PHPs http_build_query function which encodes the square brackets in the request.
The Strapi API returns a 500 error when the square brackets are encoded.
I've tried to manually make the same request without encoded square brackets, and it works.
I resorted to using Guzzle instead to make the request, as I assumed I would have more control over this. Unfortunately I encountered the same issue. Guzzle seemingly doesn't allow you to prevent url encoding of the square brackets in a query string.
Is there a way to do this without resorting to CURL? I find it odd that I seem to be the only person on the internet asking this question in the context of strapi (that I can find, anyway).