我有一个团队会议扩展应用程序,我想以编程方式将其添加到会议中。目前,我只能在会议之前、会议期间和会议之后(通过 Outlook/MS Teams)手动将应用程序添加到会议中,但我希望能够通过我的代码调用 API 来完成此操作。 Microsoft 是否提供了任何 API 端点可以让我们做到这一点?
您可以将teamsApp安装到指定的chat。如果聊天与 onlineMeeting 实例关联,那么,teamApp 将有效地安装到会议中。
var graphClient = new GraphServiceClient(requestAdapter);
var requestBody = new TeamsAppInstallation
{
AdditionalData = new Dictionary<string, object>
{
{
"[email protected]" , "https://graph.microsoft.com/v1.0/appCatalogs/teamsApps/12345678-9abc-def0-123456789a"
},
},
};
var result = await graphClient.Chats["{chat-id}"].InstalledApps.PostAsync(requestBody);