Need to see if your shared folder is taking up space on your dropbox 👨💻? Find out how to check here.
Forum Discussion
itsrainman
8 years agoExplorer | Level 3
Share a folder with team members using dropbox api v2.0
Hello, I am trying to create an app that will run on a internal remote server. The app 'listens' for XML files being generated by our BMS system and then processes these as required. The next...
itsrainman
8 years agoExplorer | Level 3
Hello Greg,
Many thanks for taking the time to respond. I've been on other stuff and have only managed to get back to this today.
So i used your suggestion.
Await dbx.Sharing.ShareFolderAsync(path)
Replacing path with my folder strFolder (/TempFolder)
Await dbx.Sharing.ShareFolderAsync(strFolder)
As soon as I tested the code it appered in my dropbox information bubble on the taskbar - great.
Now how do i send other users a link to enable them to share this folder. I assume it something along the lines of:
Await dbx.Sharing.AddFolderMemberAsync(strFolder, "someemail@email.com")
However when i get this there is an error with the message below.
System.AggregateException
HResult=0x80131500
Message=One or more errors occurred.
Source=mscorlib
StackTrace:
at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)
at System.Threading.Tasks.Task.Wait()
at ....
Inner Exception 1:
InvalidCastException: Unable to cast object of type 'System.String' to type 'System.Collections.Generic.IEnumerable`1[Dropbox.Api.Sharing.AddMember]'.
I think its because its not possible to convert the email address which is a string to an iEnumerable(of AddMember).
How do i create a list of email addresses to send the share link to?
Greg-DB
Dropbox Community Moderator
8 years agoI just dug up this old post where I wrote an example of using MemberSelector and AddMember to specify a member to add via an email address:
https://www.dropboxforum.com/t5/API-Support-Feedback/How-we-share-folder-and-file-via-dropbox-api/m-p/194299/highlight/true#M8768
It also shows how to check the shared folder job, since you need to supply the shared folder ID, not path, when adding a member. Hope this helps!
https://www.dropboxforum.com/t5/API-Support-Feedback/How-we-share-folder-and-file-via-dropbox-api/m-p/194299/highlight/true#M8768
It also shows how to check the shared folder job, since you need to supply the shared folder ID, not path, when adding a member. Hope this helps!
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!