Authorize Email Account Access is throwing error - HTTP error 401 - unauthorizedIssue This article describes how to set up an OAUTH with email accounts, for example O365 with IMAP. For more detail on scopes and values for Office 365, please see KB0816072 - Configure SMTP and IMAP email accounts with Microsoft Office365 using OAuth2.CauseWhen customer tried to configure the application registry record, they have used the client secret ID instead of client secret value.ResolutionAfter verifying the configuration, changed the client secret in the instance with the client secret value from the Azure. This resolved the issue. Tokens were successfully fetched after successful authorization.