I found this out recently that the listFolder/Continue API returns 2000 entries only. And I have also tried recursion and while loops to fetch all the metadata and add to a existing top level result.getEntries() list. But none of these approaches are working, I still see that only 2000 metadata entries are in the ultimate result.
Has anyone tried and made it work in Java?
Each page of listFolder
results, i.e., each response from a single call to listFolder
or listFolderContinue
, can contain up to about 2,000 entries. (Note that this number is not guaranteed, so you should not rely on it.)
To make sure you can get all of the items in a folder, you need to use both listFolder
and listFolderContinue
, calling back to listFolderContinue
with the latest cursor
when the hasMore
on the last call was true
. There's a working example here: