Search code examples
c#onedrivelive-sdk

How can I upload files into a shared folder on OneDrive using OneDrive API?


I am trying to upload files into a shared folder (from other users) on OneDrive using the Live SDK on Windows Runtime (version 5.6.0).

However, it seems that the current version of the SDK does not support uploading to folders of other users. Is that correct?

I can upload easily to my own folder using

client.BackgroundUploadAsync(folderId, file.Name, file, OverwriteOption.Rename);

but doing the same in other users' folder will return an unauthorization error.


Solution

  • You are correct. Live Connect does not currently support uploading files to folders other than those owned by the user on whose behalf you are making your API calls.