Jim Barrett
Jim Barrett

Reputation: 467

Is there a way to create a (Excel workbook) File using Microsoft Graph API, but not by uploading

I want to do something like

https://graph.microsoft.com/v1.0/me/drive/items/workbook/add

or similar which will create a new workbook identical to what the New -> Workbook menu does in the OneDrive Web interface.

I can't create the file locally so upload is not an option.

Upvotes: 1

Views: 1439

Answers (1)

The Microsoft Graph APIs only allow reading and modifying workbooks that already exist at this time.

I realize that your question stated you were not able to create the file locally. However, a library like js-xlsx has the ability to create workbooks in-memory that you could then push up into OneDrive using the Graph APIs. You could use a library like that to create a blank workbook, push it, then manipulate it using the Graph APIs.

Upvotes: 2

Related Questions