Receiving "The request was denied because one or more scopes requested are unauthorized or expired"

Joyce S 1 Reputation point
2021-03-02T23:28:43.32+00:00

I am going through the sample code from https://github.com/microsoftgraph/aspnet-snippets-sample
and when clicking the Mail link I get this error. 73517-1.png
I have set up the Azure AD following the instructions and set the permissions. (2.jpg) but am still receiving the same error.
What am I missing?73528-2.png

Can I just confirm the client ID that is specified in the settings file, is retrieved from Overview -> Application(client) ID, or is this the Certificates & secrets -> Client secrets -> ID ? I have tried both with the same error.

Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
12,289 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.