AADSTS700016: Application with identifier was not found in the directory
Platform Notice: Data Center - This article applies to Atlassian products on the Data Center platform.
Note that this knowledge base article was created for the Data Center version of the product. Data Center knowledge base articles for non-Data Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Problem
When attempting to integrate Jira with Microsoft Office 365 using OAuth the following error may be encountered:
Diagnosis
Environment
Jira Software version 8.10.x and later, or version 8.5.9 and later 8.5.x bug fix releases. See 3-legged OAuth Authentication for IMAP support for additional information.
Cause
This Microsoft Active Directory error code: "UnauthorizedClient_DoesNotMatchRequest - The application wasn't found in the directory/tenant. This can happen if the application has not been installed by the administrator of the tenant or consented to by any user in the tenant. You might have misconfigured the identifier value for the application or sent your authentication request to the wrong tenant."
As it relates to Jira, this commonly indicates that the wrong Client ID was entered in the Microsoft Data section when setting up OAuth integration in Jira.
Resolution
Verify the Client ID with the Administrator for the mailbox in Office 365.