We’re Still Here to Help (Even Over the Holidays!) - find out more here.
Forum Discussion
LrjRam
8 years agoNew member | Level 2
Receiving folder URL instead of file URL using list_shared_links
Hi, I was passing this API along with the parameters
EG:
URL: https://api.dropboxapi.com/2/sharing/list_shared_links
Parameters: {"path": "/10_20180815065702617/Asm_IMG-10-20181005155706.jpg"}
Instead of retuning the file path, It is returning the complete folder path.
https://www.dropbox.com/sh/6uvw8tbj6r46f28/AABOUUT2ixttiOQ_hS4QRna-a?dl=0
Please help me in this.
2 Replies
- Greg-DB8 years ago
Dropbox Community Moderator
[Cross-linking for reference: https://stackoverflow.com/questions/53052507/dropbox-receiving-folder-url-instead-of-file-url-using-list-shared-links ]
The /2/sharing/list_shared_links documentation states:
"If a non-empty path is given, returns a list of all shared links that allow access to the given path - direct links to the given path and links to parent folders of the given path. Links to parent folders can be suppressed by setting direct_only to true."
Since the file "Asm_IMG-10-20181005155706.jpg" is accessible via that folder link, the folder link is included in the result by default.
If you want it to return only links that refer to the specified directly, set the 'direct_only' parameter to true when calling. (If none exists though, and empty list will be returned.)
- LrjRam18 years agoExplorer | Level 4
Hi, It's working fine. Thanks.
About Discuss Dropbox Developer & API
Make connections with 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!