May 12 2021 11:08 AM - edited May 12 2021 11:10 AM
OnConversationUpdateActivityAsync / OnTeamsMembersAddedAsync .. It looks like this event is only triggered very first time..which means, in order to invoke this event again, I need to register the bot with new ID every time to see that event...So this is kinda inconvenient in development stage...
Is there any event that is triggered every time when the bot is added(even under same id)?
Thanks,
May 12 2021 12:24 PM
May 13 2021 05:39 AM
Here is something I found on Internet.
--------------------------
clearab commented on Jan 17, 2020 •
A couple of things to add here:
The conversationUpdate event is sent in slightly different instances depending on context:
For a 1:1 conversation between the bot and a user (personal scope) the event is only sent the very first time the bot is installed. Technically, it is sent when the conversation is created between the bot and the user. If the user uninstalls the bot, this conversation is not deleted, so if the user then re-installs the bot the event is not sent.
For Group Chats and Channels the event will be sent each time the bot is installed. This is because each time the bot is uninstalled from this context, it is actually completely removed from the conversation, so an uninstall triggers the event.
An important distinction - the event is sent on a "best effort" basis. It is not 100% guaranteed to be sent, and is definitely not 100% guaranteed to be received. Outages and transient issues can affect the send (but they should be exceedingly rare).
---------------
So If I understood correctly, it sounds like this guy is saying that if the bot was installed under Team Channel, that conversationUpdate event is triggered.
Well..here is my manifest of my bot.
"bots": [
{
"botId": ...,
"scopes": [
"team",
"personal"
]
}
],
So my bot should support team and personal scope..so I tried to install my bot under team channel...and ..then reinstalled..however, conversationUpdate wasn't triggered. Somehow my understanding wasn't correct??
Only thing I am able to see is that the conversationUpdate event is triggered ONLY the bot is fully registered again with new guid....
May 14 2021 01:49 AM
Hi @firstteam, The teamMemberAdded
event is sent to your bot if the bot is added to a conversation first time . If you want to reinstall the app first uninstall the existing app from team then again install the app into a team then you will get teamMemberAdded event.
May 15 2021 10:48 AM - edited May 15 2021 12:01 PM
BTW..Wow..Amazing...one that I've created bots(there are several due to testing)...I CANNOT find any interface that I could remove them... I went to admin page as well.....I don't see anything that I could remove the existing bots that I've created for testing..WOW...Is there any way I could remove possibly remove the bots I've created??
May 16 2021 12:38 PM
Hi @firstteam, Please go through this to remove apps in teams.
May 16 2021 01:07 PM
May 17 2021 08:00 AM
Hi @firstteam, It's not possible to delete or uninstall a bot in teams. If you want you have to delete the app from azure portal. Go to Bot Management --> Existing bot registration --> Select the bot which you want to delete and click on App registration portal hyper link as shown in the below highlighted text in image and delete the bot from azure portal.
May 17 2021 10:00 AM
May 17 2021 10:02 AM
May 17 2021 10:38 AM
May 17 2021 11:18 AM
Hi @firstteam, Because of the cache issue it may not trigger the event some times. And make sure to uninstall all the previously installed apps with that Bot Id or App ID.
May 17 2021 11:34 AM
May 18 2021 05:09 AM - edited May 18 2021 05:09 AM
Ok...I think I found out y. Well..that cache could be an issue as well..However, one thing I noticed that.... even if you uninstalled the bot, the chat bot still is there under Chat section. So...if you ever blocked it for whatever reason testing, then...when you resinstalled the app, the event won't be triggered because that bot was basically blocked. So...you have to make sure that the bot under Chat should be unblocked. Ok. here is a question. I don't see there is a delete option under Chat...or uninstall...there is hide, but I don't think that would work..I guess that is just UI thing... Is there any way to make a sort of automatic way that I can unblock the bot whenever I uninstalled the app? Obviously, I could create new bot(new guid), but that is not my option at this point.
Thanks,
May 22 2021 05:49 AM
Hi @firstteam, Currently there is no option to block a bot in specific chat.