OneDrive / onedrive-sdk-csharp

OneDrive SDK for C#! https://dev.onedrive.com
Other
294 stars 143 forks source link

Share a folder and upload a file #258

Closed jrichardsz closed 1 month ago

jrichardsz commented 2 months ago

Hi.

My required flow is to create a folder, upload a file and share the folder to some users using onedrive. According to my research, I can create a folder, upload a file but I can't find how to share the folder

(1) Create folder

var folderToCreate = new Item { Name = folderName, Folder = new Folder() };
var newFolder = await client.Drive.Items[parentId].Children.Request().AddAsync(folderToCreate);

(2) Upload a file

upload files successfully via
item = await oneDriveClient.Drive.Root.ItemWithPath(itemPath).Content.Request().PutAsync<Item>(memStream);

(3) Share to some user

Is it possible using this SDK/Api or Should I use Sharepoint for that?

Thank you

baywet commented 1 month ago

Thank you for reaching out and for your patience. This SDK is being officially deprecated. See #259 for more information