We are aware of the issue with the badge emails resending to everyone, we apologise for the inconvenience - learn more here.
Forum Discussion
vsipchenko
7 years agoExplorer | Level 4
Does sharing_create_shared_link_with_settings create new link every time?
I am using python SDK and looking at 2 different methods:
1. sharing_create_shared_link 2. sharing_create_shared_link_with_setting
So from documentation I see that first method returns previ...
- 7 years ago
No, sharing_create_shared_link_with_settings does not work the same way. If you call it for a path for which there is already a shared link, it will give a CreateSharedLinkWithSettingsError.shared_link_already_exists error. In that case, you can call sharing_list_shared_links with direct_only=True to retrieve the existing link.
Greg-DB
Dropbox Staff
No, sharing_create_shared_link_with_settings does not work the same way. If you call it for a path for which there is already a shared link, it will give a CreateSharedLinkWithSettingsError.shared_link_already_exists error. In that case, you can call sharing_list_shared_links with direct_only=True to retrieve the existing link.
kevin g.1
4 years agoHelpful | Level 6
Hi Greg,
Is it possible to emulate the behavior of the deprecated sharing_create_shared_link method where the existing shared link is returned by default instead of having to catch the error and make another api call to list the existing shared links?
- Greg-DB4 years agoDropbox Staff
kevin g.1 It's not possible to recreate the sharing_create_shared_link behavior with sharing_create_shared_link_with_settings exactly, but in some cases the API will return the existing shared link metadata in the SharedLinkAlreadyExistsMetadata in the CreateSharedLinkWithSettingsError, which you can get via CreateSharedLinkWithSettingsError.get_shared_link_already_exists to streamline the process. If not though, you do still need to make the extra API call.
- kevin g.14 years agoHelpful | Level 6
Hi,
Thanks for the helpful response. Are those cases where the metadata isn't returned documented?
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
5,877 PostsLatest Activity: 12 months agoIf 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 or Facebook.
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!