I am trying to use an Azure AD App Registration with a WPF application to upload and download files using Sharepoint Online.
I used https://docs.microsoft.com/en-us/azure/active-directory/develop/tutorial-v2-windows-desktop to authenticate.
I have set up the login, and this works without problem. I get the tokens back. (Microsoft.Identity.Client 4.6)
I added the sharepoint graph API delegated "Sites.FullControl.All"
I tried using the nuget packages SharePointPnPCoreOnline and Microsoft.SharePointOnline.CSOM with the access token from the Azure AD login.
The App registration is created in the same tenant as the sharepoint.
No matter what I try, I cannot get this to work. (401 returned)
I want to CRUD files in a sharepoint List.
Have you any ideas, how I could solve this, examples? Or is there any docs for this?