[fix] pagination does not work?
giganteous opened this issue ยท 9 comments
Describe the bug
Node.js version: N/A
OS version: API consumer (python requests / curl)
Description: Pagination limit field and page field do not work
Actual behavior
- I'm getting a limit of 50, even if I specify a limit of 10
- i'm getting only page 1, even if I specify page 2.
Expected behavior
- a limit of 10 if I hand curl a query parameter "&limit=10"
- the 29 remaining results on page 2 when I specify "&page=2"
Code to reproduce
$ curl 'https://api.forwardemail.net/v1/domains/foef.nl/aliases?page=1&limit=10&pagination=true' -u secret: > p1.json
$ curl 'https://api.forwardemail.net/v1/domains/foef.nl/aliases?page=2&limit=10&pagination=true' -u secret: > p2.json
$ md5sum p*.json
011961c036cab33f21e24db013650de2 p1.json
011961c036cab33f21e24db013650de2 p2.json
Checklist
- [ x] I have searched through GitHub issues for similar issues.
- [ x] I have completely read through the README and documentation.
- I have tested my code with the latest version of Node.js and this package and confirmed it is still not working.
free text
Since the result is so weird I'm almost thinking I'm doing things wrong. but here we go.
It does see that I want pagination, the length of the resultset in p1 and p2 are 50; the first 50 results in the total resultse, count is 79 in total.
@giganteous thanks for posting this, taking a look
The minimum is 50 right now.
We'll fix this though and update our API docs.
@giganteous ๐ we've deployed the fix as per 0014692
Can you let us know if this works OK for you now or if you still have issues?
Thank you for reporting this ๐
Well, I only have 79 results, they easily fit in the 1000 that you will support after oktober. So, I don't have an "issue".
But, I can't get page 2 to work, even without specifying a limit: I'm getting page 1, the results are identical. Do you need my assistance? Headers?
Thanks for diving into it! :)
We're going to write another test case and see if we can reproduce and then issue another fix.
Confirmed this is a bug, fixing now and will ping you back once done.
@giganteous this is now fixed & deployed per cf15429 ๐ can you try again and let us know? ๐
@giganteous this is now fixed & deployed per cf15429 ๐ can you try again and let us know? ๐
Works like a charm! Sorry for the delay. I'm getting a page2 with only 29 items now. Perfect.