We’re Still Here to Help (Even Over the Holidays!) - find out more here.
Forum Discussion
jeff00coder
7 years agoExplorer | Level 4
API: Folder and Recursive search for File or Folder by name (and by extension)?
Good day,
Through the main user console of an Dropbox account, one can search for files by name:
https://help.dropbox.com/files-folders/sort-preview/search
It is not clear looking at the API documentation if it possible via API to search for a file (by name or extension) and for a Folder (by name)?
Search either:
- Only within a specific Folder (not recursive) given Path or ID?
- Recursively from a Folder given Path or ID?
Thx
1 Reply
- Greg-DB7 years ago
Dropbox Community Moderator
The Dropbox API does offer the ability to programmatically search in the connected account, with a number of different options. You can find more information in the documentation here:
https://www.dropbox.com/developers/documentation/http/documentation#files-search
You can specify the query, such as a file or folder name or file extension, that you want to search for you in the "query" parameter.
You can also restrict the search to a particular path using the "path" parameter under the "options" field, specifying either path or ID.
It's not currently possible to request non-recursive search, but I'll pass this along as a feature request. I can't promise if or when that might be implemented though.
About 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!