DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’» is a community of 963,673 amazing developers

We're a place where coders share, stay up-to-date and grow their careers.

Create account Log in
Cesar Codes
Cesar Codes

Posted on

Uploading Large Files to OneDrive with Microsoft Graph API

Using Microsoft's Graph API, you can easily upload files to OneDrive. However, you may run into limitations when uploading files larger than 4MB (as of early 2020). Luckily, we can easily upload large files with an upload session, as demonstrated below.

To learn more about upload sessions, you can refer to the
official docs.

First thing you want to do is get an access token. This is an example of how to do it with cURL:

Then, you can utilize the C# client, like this:

Happy Coding,
Cesar

Top comments (1)

Collapse
 
sn3akyp3t3 profile image
Sn3akyP3t3

🌚 Life is too short to browse without dark mode