Hey guys I am trying to do something that I thought it will be very easy, but the lack of documentation and confusing error messages is make this almost impossible for me, could be also my lack of knowledge. All suggestions links on this forum are giving me 404 error. Anyways, here is my problem:
I am using .NET SDK
PackageReference Include="Dropbox.Api" Version="6.36.0"
What I want to do is:
- Create a folder
- Share this folder with another dropbox account (not member of my team)
here is my code:
var folder = await dbx.Files.CreateFolderV2Async("/newfolder");
var folderId = dbx.Sharing.ShareFolderAsync(
new Dropbox.Api.Sharing.ShareFolderArg(
"/newfolder",
new Dropbox.Api.Sharing.AclUpdatePolicy().AsEditors,
false,
null,
null,
null,
null,
null, //new List<Dropbox.Api.Sharing.FolderAction> { new Dropbox.Api.Sharing.FolderAction().AsEditContents },
new Dropbox.Api.Sharing.LinkSettings(new Dropbox.Api.Sharing.AccessLevel().AsEditor
))).Result.AsComplete.Value.SharedFolderId;
await dbx.Sharing.AddFolderMemberAsync(
new Dropbox.Api.Sharing.AddFolderMemberArg(folderId, new List<Dropbox.Api.Sharing.AddMember>
{
new Dropbox.Api.Sharing.AddMember (new Dropbox.Api.Sharing.MemberSelector.Email("any@email.com") )
}));
If I use :
var folderId = dbx.Sharing.ShareFolderAsync(
new Dropbox.Api.Sharing.ShareFolderArg("/Course1234569") )
it worked, however the folder is ready only for the email I shared with.
I need the person I shared the folder with having Editor access (Can read and write)
Please Help.