Warning: Trying to access array offset on value of type null in /www/wwwroot/app-pack.telkomuniversity.ac.id/wp-content/themes/sinrato/functions.php on line 40
AADSTS65001: The user or administrator has not consented to use the application with ID
Trying to create a simple SPA and call a Rest API in Azure, and I am getting InteractionRequiredAuthError: AADSTS65001: The user or administrator has not consented to use the application with ID ‘xxx’ named ‘MySpaApp’. Send an interactive authorization request for this user and resource. Did the following: Registered the REST Api applicationAdded permission for MyRestApi.Tasks.Get, its status is Granted for my usersAdded a scope for Tasks.GetAdded a client application using the SPA application’s Client Id Registered the SPA applicationURI is http://localhostImplicit grant and hybrid flows:–Access tokens checked–ID tokens checked–Supported account types: any organizational directory–API Permissions, added MyRestApi.Tasks.Get In Enterprise Applications, MySpaApp, clicked Grant Admin Consent for my users Went back to MySpaApp, and verified that Tasks.Get has been granted From MySpaApp, if I call msal.acquireTokenSilent with “Tasks.Get” for scope, I get: The user or administrator has not consented to use the application with ID ‘xxx’ named ‘MySpApp’. Send an interactive authorization request for this user and resource. If I call call msal.acquireTokenSilent with “User.Read” for scope, I get back a token.Any further ideas on troubleshooting? Trying to create a simple SPA and call a Rest API in Azure, and I am getting InteractionRequiredAuthError: AADSTS65001: The user or administrator has not consented to use the application with ID ‘xxx’ named ‘MySpaApp’. Send an interactive authorization request for this user and resource.
Did the following:
Registered the REST Api applicationAdded permission for MyRestApi.Tasks.Get, its status is Granted for my usersAdded a scope for Tasks.GetAdded a client application using the SPA application’s Client Id
Registered the SPA applicationURI is http://localhostImplicit grant and hybrid flows:–Access tokens checked–ID tokens checked–Supported account types: any organizational directory–API Permissions, added MyRestApi.Tasks.Get
In Enterprise Applications, MySpaApp, clicked Grant Admin Consent for my users
Went back to MySpaApp, and verified that Tasks.Get has been granted
From MySpaApp, if I call msal.acquireTokenSilent with “Tasks.Get” for scope, I get: The user or administrator has not consented to use the application with ID ‘xxx’ named ‘MySpApp’. Send an interactive authorization request for this user and resource.
If I call call msal.acquireTokenSilent with “User.Read” for scope, I get back a token.
Any further ideas on troubleshooting?