I am writing a test application which uses AAD to get acquire token, and this call succeeds for one user with TenantId "abc" but fails for another user with tenantId "xyz" with the message:
The user or administrator has not consented to use the application with ID
f5986c14-cdb9-4e68-a89e-119d15b33afc. Send an interactive authorization request for this user and resource.
Please note:
I have created one native application in my AAD
I have added those users from another tenant into the Users list of the directory as User role and also, we granted the permissions for the native app to all the users in the directory in windows azure management portal Screenshot Here
The IT administrator of the company with xyz domain ([email protected]) has to give consent on behalf of the whole company so that the users of that company will be able to use your application. Here is a very good example of the flow:
https://blog.mastykarz.nl/implementing-admin-consent-multitenant-office-365-applications-implicit-oauth-flow/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With