aspnetcore-connect-sample | NET Core MVC sample shows how to connect to Microsoft Graph | Azure library
kandi X-RAY | aspnetcore-connect-sample Summary
kandi X-RAY | aspnetcore-connect-sample Summary
page_type: sample description: "Use ASP.NET Core 3.1 MVC to connect to Microsoft Graph using the delegated permissions flow." products:.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of aspnetcore-connect-sample
aspnetcore-connect-sample Key Features
aspnetcore-connect-sample Examples and Code Snippets
Community Discussions
Trending Discussions on aspnetcore-connect-sample
QUESTION
I am struggling to get user information from Azure AD, with Microsof Graph with a .NET Core API. I tried a couple tutorials but I got stuck on several issues.
Microsoft Graph Connect Sample for ASP.NET Core 3.1 https://docs.microsoft.com/en-us/samples/microsoftgraph/aspnetcore-connect-sample/microsoft-graph-connect-sample-for-aspnet-core-31/)
This tutorial look promising, but it turns out it requires a multi tenant Azure Application - but mine is Single Tenant.
Call MS Graph APIs from ASP.NET Core 3.1 (https://github.com/cmatskas/aspnetcorewithgraph/blob/master/WebApplication1/Startup.cs)
This tutorial look interesting but it uses two NuGet packages in preview mode. And when I try the code (see my startup.cs) it throws issues saying
"The MetadataAddress or Authority must use HTTPS unless disabled for development by setting RequireHttpsMetadata=false."
I tried set it to false in my addJwTBearer option, but the issue remains.
Any chance you guys know of a good tutorial for my case, or what is wrong with my startup file?
Startup.cs
...ANSWER
Answered 2020-Sep-29 at 22:15Microsoft Graph Connect Sample for ASP.NET Core 3.1 should work with single tenant applications.
Update GraphAuthProvider.cs line 28 to:
QUESTION
I have the following function to call users from active directory use graph api. This function is hit on each keyup of a text box. But i am getting following error
Code: TokenNotFound Message: User not found in token cache. Maybe the server was restarted.
in this line of code
...ANSWER
Answered 2020-Apr-16 at 16:05I think that is probably caused by the token that is not well persisting in memory cache,
Otherwise, maybe you are restarting your apps when you close the browser so you need to disable this option in VS because when you restarting the app it's clear all temporary data in memrory .
you can follow these steps disabling this feature:
Go into Tools -> Options, then navigate into Projects and Solutions -> Web Projects and uncheck the option Stop debugger when the browser window is closed.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install aspnetcore-connect-sample
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page