Wählen Sie für diese API die Als am wenigsten privilegierten Berechtigungen gekennzeichneten Berechtigungen aus. Verwenden Sie nur dann eine Berechtigung mit höheren Berechtigungen , wenn dies für Ihre App erforderlich ist. Ausführliche Informationen zu delegierten Berechtigungen und Anwendungsberechtigungen finden Sie unter Berechtigungstypen. Weitere Informationen zu diesen Berechtigungen finden Sie in der Berechtigungsreferenz.
Die Berechtigungen TeamsAppInstallation.ReadWriteAndConsentSelfForChat und TeamsAppInstallation.ReadWriteAndConsentForChat verwenden eine ressourcenspezifische Zustimmung.
HTTP-Anforderung
GET /chats/{chat-id}/installedApps/{app-installation-id}
GET https://graph.microsoft.com/v1.0/chats/19:d65713bc498c4a428c71ef9353e6ce20@thread.v2/installedApps/MTk6ZDY1NzEzYmM0OThjNGE0MjhjNzFlZjkzNTNlNmNlMjBAdGhyZWFkLnYyIyMwMDAwMTAxNi1kZTA1LTQ5MmUtOTEwNi00ODI4ZmM4YTg2ODc=
// Code snippets are only available for the latest version. Current version is 5.x
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Chats["{chat-id}"].InstalledApps["{teamsAppInstallation-id}"].GetAsync();
// THE CLI IS IN PREVIEW. NON-PRODUCTION USE ONLY
mgc chats installed-apps get --chat-id {chat-id} --teams-app-installation-id {teamsAppInstallation-id}
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
TeamsAppInstallation result = graphClient.chats().byChatId("{chat-id}").installedApps().byTeamsAppInstallationId("{teamsAppInstallation-id}").get();
Beispiel 2: Abrufen des Ressourcenspezifischen Berechtigungssatzes, der für die im angegebenen Chat installierte App zugestimmt wurde
Im folgenden Beispiel wird die Liste aller ressourcenspezifischen Berechtigungen abgerufen, die einer App im Rahmen der Installation gewährt wurden. Ein $select Abfrageparameter ist erforderlich, um den zustimmungswilligen Berechtigungssatz anzuzeigen.
GET https://graph.microsoft.com/v1.0/chats/19%5bd86ec7f6b247d3b9e519b0bfef5d03%40thread.v2/installedApps/MTk6NWJkODZlYzdmNmIyNDdkM2I5ZTUxOWIwYmZlZjVkMDNAdGhyZWFkLnYyIyMyYjUyNGUyOC05NWNlLTRjOWItOTc3My00YTViZDZlYzE3NzA=?$select=consentedPermissionSet,id
// Code snippets are only available for the latest version. Current version is 5.x
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Chats["{chat-id}"].InstalledApps["{teamsAppInstallation-id}"].GetAsync((requestConfiguration) =>
{
requestConfiguration.QueryParameters.Select = new string []{ "consentedPermissionSet","id" };
});
// THE CLI IS IN PREVIEW. NON-PRODUCTION USE ONLY
mgc chats installed-apps get --chat-id {chat-id} --teams-app-installation-id {teamsAppInstallation-id} --select "consentedPermissionSet,id"
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
TeamsAppInstallation result = graphClient.chats().byChatId("{chat-id}").installedApps().byTeamsAppInstallationId("{teamsAppInstallation-id}").get(requestConfiguration -> {
requestConfiguration.queryParameters.select = new String []{"consentedPermissionSet", "id"};
});
Bald verfügbar: Im Laufe des Jahres 2024 werden wir GitHub-Issues stufenweise als Feedbackmechanismus für Inhalte abbauen und durch ein neues Feedbacksystem ersetzen. Weitere Informationen finden Sie unter https://aka.ms/ContentUserFeedback.