Forum Discussion

varun m.1's avatar
varun m.1
New member | Level 2
10 years ago

Dropbox API v2 listFolder sort files by creation time

Hi

 

I am using Java SDK of Dropbox API v2 in my Android app. I use listFolder() to list the contents of the folder. This folder only has files in it, no sub folders.

 

ListFolderResult result = mDbxClient.files().listFolder(somePath);

 I want 'result' to contain files ordered by:

1. Creation time on server

2. Name of file

 

How can I achieve this? Please help.

7 Replies

  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Community Moderator rankDropbox Community Moderator
    10 years ago

    The API doesn't offer options for sorting/ordering the returned metadata, but I'll be sure to pass this along as a feature request. 

     

    You can sort the entries in your application's own code of course after you receive them, but make sure you process them in the order returned first to make sure you get an accurate representation of the account, per the documentation.

  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Community Moderator rankDropbox Community Moderator
    4 years ago

    hb-dev No, unfortunately there's no news on this request.

  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Community Moderator rankDropbox Community Moderator
    4 years ago

    Rolana No, I don't have any news on this feature request.

About Dropbox API Support & Feedback

Node avatar for Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.

The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!