简体   繁体   English

从 zip 安装 Teams Bot 应用程序时未触发 onMembersAdded 事件

[英]onMembersAdded event is not firing when installing Teams Bot app from zip

I would like to send the user a welcome message when they install my MS Teams Bot app.我想在用户安装我的 MS Teams Bot 应用程序时向他们发送欢迎消息。 All the samples and documentation point to using the ActivityHandler onMembersAdded event.所有示例和文档都指向使用 ActivityHandler onMembersAdded 事件。 Unfortunately I can't get this event to fire.不幸的是,我无法触发此事件。 I also noticed that when installing the zip file in Teams and watching the requests in ngrok nothing happens;我还注意到,在 Teams 中安装 zip 文件并在 ngrok 中查看请求时没有任何反应; so I'm not entirely sure the problem is in my bot app.所以我不完全确定问题出在我的机器人应用程序中。 Is there something I need to do in the manifest?清单中有我需要做的事情吗?

If I chat with my app the onMessage event will fire, but like I said above, I need to send a "Welcome" message when the app is installed before the user starts typing.如果我与我的应用程序聊天,onMessage 事件将触发,但就像我上面所说的,我需要在安装应用程序时在用户开始输入之前发送一条“欢迎”消息。

Background: I created the manifest for my app using App Studio in Teams and exported it to a zip The node app is built with the using botbuilder 4.9.2背景:我在 Teams 中使用 App Studio 为我的应用程序创建了清单并将其导出到 zip 节点应用程序是使用 botbuilder 4.9.2 构建的

onMembersAddedAsync works everywhere, but not in Teams:) For Teams, there is a set of separate methods that work only in Teams. onMembersAddedAsync 适用于任何地方,但不适用于 Teams:) 对于 Teams,有一组单独的方法仅适用于 Teams。 You need to use OnTeamsMembersAddedAsync.您需要使用 OnTeamsMembersAddedAsync。 You can read more about that here: https://docs.microsoft.com/en-us/microsoftteams/platform/bots/how-to/create-a-bot-for-teams您可以在此处阅读更多相关信息: https://docs.microsoft.com/en-us/microsoftteams/platform/bots/how-to/create-a-bot-for-teams

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 messageReactionAdd 事件仅在机器人对消息做出反应时触发 - messageReactionAdd event is only firing when the bot reacts to a message 在Microsoft团队中安装机器人,该机器人名称是Azure主机,而不是任务中指定的机器人名称 - Installing a bot in Microsoft teams, the bot name is the Azure host not the bot name specified in the mandate 当机器人在 Teams 中发送消息时,我如何获得通知? - How do I get notifications when a bot sends a message in Teams? MS Teams bot - 如何从 nodejs 代码下载在团队中上传的文件 - MS Teams bot - how to download file that was uploaded in teams from nodejs code 无法将Bot的pdf文件发送给ms团队中的用户 - Unable to send pdf file from bot to user in ms teams Teams Bot 与 Teams 当前用户进行身份验证 - Teams Bot Authenticate with Teams Current User 当用户更新其个人资料图片时在 Microsoft Teams 中触发的事件 - Event triggered in Microsoft Teams when a user updated its profile picture Microsoft Teams - 深度链接到机器人选项卡 - Microsoft Teams - Deeplink to bot tab Teams Bot 开发中的对话概念 - Concept of Conversations in Teams Bot development 使用 Team 的附件按钮在机器人应用程序中上传文件时,Microsoft Teams 返回错误 - Microsoft Teams returning error when file is uploaded in bot application using Team's attachment button
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM