onTeamsMembersAddedEvent function not getting invoked when a user installs a bot in personal scope

%3CLINGO-SUB%20id%3D%22lingo-sub-1529242%22%20slang%3D%22en-US%22%3EonTeamsMembersAddedEvent%20function%20not%20getting%20invoked%20when%20a%20user%20installs%20a%20bot%20in%20personal%20scope%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1529242%22%20slang%3D%22en-US%22%3E%3CP%3EI'm%20installing%20the%20bot%20in%20user's%20personal%20scope%20with%20the%20help%20of%20%3CSTRONG%3Egraph%20API%26nbsp%3B%3C%2FSTRONG%3Eusing%26nbsp%3B%20%3CA%20href%3D%22https%3A%2F%2Fgraph.microsoft.com%2Fbeta%2Fusers%2F%7Bid%7D%2Fteamwork%2FinstalledApps%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fgraph.microsoft.com%2Fbeta%2Fusers%2F%7Bid%7D%2Fteamwork%2FinstalledApps%3C%2FA%3E%26nbsp%3Bfor%20getting%20the%20user's%20conversation%20reference%20but%20in%20the%20backend%20code%2C%20the%26nbsp%3B%3CSTRONG%3EonTeamsMembersAddedEvent%26nbsp%3B%3C%2FSTRONG%3Efunction%20is%20not%20getting%20invoked%20due%20to%20which%20I'm%20unable%20to%20store%20the%20conversation%20reference%20and%20also%20not%20able%20to%20send%20a%20welcome%20message%20to%20user%2C%20It%20was%20working%20perfectly%20fine%20for%20the%20past%20couple%20of%20months%20but%20suddenly%20today%20morning%20it%20stopped%20getting%20invoked.%26nbsp%3B%3C%2FP%3E%3CP%3EAlso%20I%20tried%20manually%20installing%20the%20bot%20in%20my%20personal%20scope%20but%20still%20facing%20the%20same%20problem.%20It%20is%20getting%20invoked%20only%20when%20a%20user%20tries%20to%20install%20the%20bot%20in%20a%20team.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EP.S.%20-%20I'm%20using%20latest%20%3CSTRONG%3Ebotframework%3C%2FSTRONG%3E%20for%20implementing%20the%20bot%20and%20the%20%3CSTRONG%3Ebotbuilder%3C%2FSTRONG%3E%20module.%20I'm%20using%20Node.js%20with%20JavaScript%20to%20implement%20it.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSTRONG%3E%3CFONT%20color%3D%22%23FF0000%22%3EPlease%20help%20me%20if%20you%20have%20any%20solution.%3C%2FFONT%3E%3C%2FSTRONG%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1529242%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EBot%20Framework%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EDeveloper%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EMicrosoft%20Teams%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ENode.js%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1538703%22%20slang%3D%22en-US%22%3ERe%3A%20onTeamsMembersAddedEvent%20function%20not%20getting%20invoked%20when%20a%20user%20installs%20a%20bot%20in%20personal%20sco%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1538703%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F731960%22%20target%3D%22_blank%22%3E%40hardikverma%3C%2FA%3E%26nbsp%3BCould%20you%20please%20help%20us%20with%20the%20error%3F%20Please%20take%20a%20look%20at%20this%20documentation%2C%20it%20contains%20the%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fbot-service%2Fbot-builder-send-welcome-message%3Fview%3Dazure-bot-service-4.0%26amp%3Btabs%3Dcsharp%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Esample%20code%20for%20Bot%20SDK%20V4%3C%2FA%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
New Contributor

I'm installing the bot in user's personal scope with the help of graph API using  https://graph.microsoft.com/beta/users/{id}/teamwork/installedApps for getting the user's conversation reference but in the backend code, the onTeamsMembersAddedEvent function is not getting invoked due to which I'm unable to store the conversation reference and also not able to send a welcome message to user, It was working perfectly fine for the past couple of months but suddenly today morning it stopped getting invoked. 

Also I tried manually installing the bot in my personal scope but still facing the same problem. It is getting invoked only when a user tries to install the bot in a team.

 

P.S. - I'm using latest botframework for implementing the bot and the botbuilder module. I'm using Node.js with JavaScript to implement it.

 

Please help me if you have any solution.

1 Reply
Highlighted

@hardikverma Could you please help us with the error? Please take a look at this documentation, it contains the sample code for Bot SDK V4