How to send email from any one email using Microsoft Graph

Please note that since Graph API v. 5.0 (march 2023), Microsoft introduced an annoying breaking change, not really well documented (besides obscurely here). Now, SendMail cannot be used anymore as a method of a User. You will get a CS1955 Non-invocable member cannot be used like a method compiler error if you try to do … Read more

SharePoint Rest API how to get Access Token?

To call SharePoint specific APIs you need to get a SPO specific access token. You can “swap” an regular MS Graph refresh token for an SPO specific token by doing the following: Get a delegated auth token from graph as you normally would (https://learn.microsoft.com/en-us/graph/auth-v2-user) Use the refresh_token you got and exchange it for an SPO … Read more

Upload file to SharePoint drive using Microsoft Graph

In order to get all the files of a drive using v1.0, you would first need to get an access token (which I see you are already passed that), then get the ‘drive-id’ and use the following URL(note: its not ‘drive’ it is ‘drives’): https://graph.microsoft.com/v1.0/drives/{drive-id}/root/children To get the drive id, I made the following GET … Read more

Which Graph API should be used with Azure AD B2C

As of today, we recommend that you use the Azure Active Directory Graph API https://graph.windows.net to access and manage your B2C tenants. Azure AD B2C: Use the Graph API If you read this article, you can learn more about the gaps between AAD and Microsoft Graph API: https://dev.office.com/blogs/microsoft-graph-or-azure-ad-graph The bottom line in the table states: … Read more