Forum Discussion
Attempting to install the Teams app into a meeting using the Graph API returns a 404:Not Found value
Hi,
I'm working on a Java back end application. Its purpose is to:
1. Automatically create an online meeting when certain conditions are met.
2. After creating an online meeting, install a specific Bot app published to the organization in the online meeting chat window.
Creating an online meeting was successful with setting the appropriate API permissions for the app.
The problem is number 2. Authorization of the app was granted through the Graph API document, and the Bot app to be installed was also published normally by the organization. It was also confirmed that the app was retrieved through the API that retrieves the app list. However, when I try to install using the Graph api, 404:Not Found is returned. What's wrong?
For reference, my organization's settings are as follows:
1. Permission to use API of Java back end app:
- OnlineMeetings.ReadWrite.All
- AppCatalog.ReadWrite.All
- Application.ReadWrite.All
- OnlineMeetings.ReadWrite.All
- TeamsAppInstallation.ReadWriteForChat.All
2. Bot app
- Published to organization (permissions and other settings are all allowed)
3. Teams apps Permission policies
-Custom apps: Allow all apps
The following is the return value when a 404 error occurs.
mplementation 'com.microsoft.graph:microsoft-graph:5.+'
implementation 'com.azure:azure-identity:1.+'
{"email address removed for privacy reasons":"https://graph.microsoft.com/v1.0/appCatalogs/teamsApps/2b0140e9-de04-4097-976d-3b646fc8c082"}
404 : Not Found
client-request-id : 2402818b-c253-4e02-840b-7968928cec67
Content-Type : application/json
Date : Thu, 17 Aug 2023 08:40:08 GMT
request-id : 9d88ee5a-6cc4-46bb-b99d-270893abdaca
Strict-Transport-Security : max-age=31536000
Transfer-Encoding : chunked
Vary : Accept-Encoding
{
"error": {
"code": "NotFound",
"message": "NotFound",
"innerError": {
"message": "",
"code": "AppDefinitionDoesntExist",
"innerError": {},
"date": "2023-08-17T08:40:09",
"request-id": "9d88ee5a-6cc4-46bb-b99d-270893abdaca",
"client-request-id": "2402818b-c253-4e02-840b-7968928cec67"
}
}
}
Thanks.
- Prasad_Das-MSFTMicrosoft
The error message indicates that the app definition doesn't exist, which means that the Teams app you are trying to install in the meeting is not found. This could be due to various reasons such as:
-
Incorrect app ID or app package ID: Make sure that you are using the correct app ID or app package ID when installing the app. Double-check the ID in your code or configuration.
-
App not uploaded or published: Ensure that you have uploaded and published the app in the Teams admin center or the Microsoft Teams App Studio. Without publishing the app, it won't be available for installation.
-
App manifest not configured correctly: Check the app manifest file (app package) to ensure that it is configured correctly. The manifest file contains the necessary information about the app, including its capabilities, permissions, and endpoints.
Thanks,
Prasad Das
------------------------------------------------------------------------------------------
If the response is helpful, please click "**Mark as Best Response**" and like it. You can share your feedback via Microsoft Teams Developer Feedback link.
- LeeJinWooCopper ContributorHi, Thanks for your advice.
I guess I've probably found a suitable app ID value. This time, the error code has been changed as follows. What should I check for the ResourceSpecificPermissionsMismatch code?
POST https://graph.microsoft.com/v1.0/chats/19:meeting_MzA4NDcxM2ItMWIyNy00ODVlLTgzMjQtNjg5MWI0MGJjNTVi@thread.v2/installedApps
SdkVersion : graph-java/v5.68.0
{"email address removed for privacy reasons":"https://graph.microsoft.com/v1.0/appCatalogs/teamsApps/7613b7c9-d091-4920-a3b8-ee45efc78714"}
{
"error": {
"code": "BadRequest",
"message": "BadRequest",
"innerError": {
"message": "",
"code": "ResourceSpecificPermissionsMismatch",
"innerError": {},
"date": "2023-08-22T01:03:40",
"request-id": "a9d431bc-9fcf-4b5a-968d-7f8379d71c70",
"client-request-id": "13a32ae1-4743-41ab-8324-931c0c09f66b"
}
}
}
Thanks,
Lee- Prasad_Das-MSFTMicrosoft
LeeJinWoo - This error occurs when the permissions required to access a specific resource are not properly configured or granted. To resolve this issue, you need to ensure that the necessary permissions are granted for the resource you are trying to access.
-
Identify the resource for which the permissions are mismatched. In this case, it could be "installedApps" resource.
-
Make sure that the app registration in Azure Active Directory (AAD) has been granted the necessary permissions. You can do this by navigating to the Azure portal, selecting the app registration, and configuring the required permissions under the "API permissions" section.
-
If the permissions are already configured correctly, try refreshing the access token or obtaining a new access token to ensure that the updated permissions are applied.
-
-