Sometimes, when trying to enable Okta Multi-Factor Authentication (MFA) from Microsoft Azure AD, the below error might be seen:
Please review the form to correct the following error(s):
UNEXPECTED_ERROR
Additionally, the System Logs will show the following error:
Could not validate your Office 365 credentials, received error: 400 AADSTS50126
- Microsoft Entra ID (formerly Microsoft Azure AD)
- Microsoft 365 (M365)
- Multi-Factor Authentication (MFA)
The Advanced API Access is not enabled.
To resolve the issue:
- Navigate to the Sign On tab of the Okta Office 365 app.
- Under Settings > API CREDENTIALS > Advanced API Access, select the checkbox for Allow administrator to consent for advanced API access.
