吳文喬
吳文喬

Reputation: 171

AADSTS650051: Application 'CLIENT_ID' is requesting permissions that are either invalid or out of date

This question is similar to

AADSTS65005: Application 'CLIENT_ID' is requesting permissions that are either invalid or out of date."

But the situation is a little different:

  1. I removed registered application from AAD
  2. Auth this application
  3. This error AADSTS650051 comes.
  4. Then I auth this application again, it works.

Is any way to avoid this behavior? Maybe add some query?

Thanks!

Upvotes: 2

Views: 4349

Answers (1)

Marilee Turscak - MSFT
Marilee Turscak - MSFT

Reputation: 7728

This is almost always related to a discrepancy between the app registration + app settings in the portal and what you have in your code.

Your application ID in the portal needs to match the client ID in your code, the sign-on URL needs to be the homepage URL starting with HTTPS and needs to match the configuration, reply url/redirectURI need to match, and the app needs to be registered under the right tenant that also matches what you have in your config.

If all of your settings and permissions are correct then you really should not receive this error.

Upvotes: 1

Related Questions