Need to see if your shared folder is taking up space on your dropbox 👨💻? Find out how to check here.
Forum Discussion
chakmangoo
3 years agoExplorer | Level 4
File path from URL
Hello,
Is there any way to get file path from file's URL.
Example: If a file - "fileName.m4v" lives inside "folder1/sub-folder1" and its dropboxURL is https://www.dropbox.com/s/something/fileName.m4v?dl=0.
I am looking for function/code that takes URL as parameter and returns filePath ("folder1/sub-folder1/fileName.m4v")
chakmangoo wrote:...
I am looking for function/code that takes URL as parameter and returns filePath ("folder1/sub-folder1/fileName.m4v")
Hi chakmangoo,
It's only possible if the authenticated account is the one that own the shared link. In such a case you can use /2/sharing/get_shared_link_metadata.
Hope this helps.
PS: Take in mind that Dropbox non empty path always starts with slash (not directly with the first folder or file name as in your post). The path form, you posted, is invalid!
1 Reply
- Здравко3 years agoLegendary | Level 20
chakmangoo wrote:...
I am looking for function/code that takes URL as parameter and returns filePath ("folder1/sub-folder1/fileName.m4v")
Hi chakmangoo,
It's only possible if the authenticated account is the one that own the shared link. In such a case you can use /2/sharing/get_shared_link_metadata.
Hope this helps.
PS: Take in mind that Dropbox non empty path always starts with slash (not directly with the first folder or file name as in your post). The path form, you posted, is invalid!
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!