Home > Mobile >  Proactive Messaging in MS Teams
Proactive Messaging in MS Teams

Time:03-22

I am trying to build a bot that can initiate a message direclty to a user who is in our organization (i.e. not a message into a Teams channel). I was only able to do this with the following methods:

  1. when the user initiates the conversation?
  2. when the user install the apps from the app store (the bot app is available)
  3. when the user is added to the teams channel where the app is installed.

I have spent a huge amount of time searching the solution documentation and now I'm getting the feeling that my requirement is not possible. It would be really nice if someone has some leads on it?

Thanks in advance

CodePudding user response:

The proactive messages are like three types in major

  1. Welcome messages
  2. Notification
  3. Schedules

These messages are given by the bot that are not in response to a particular question by the user The bot have access to all the dependent applications and the users, group chats and teams channel. First you need to create the bot and install in the location. For example if person 1 is getting response, his device or application must be having the plugin installed of the bot. For further reference check the document document2

CodePudding user response:

Per the conversation above in the original post, Bots in Teams can only continue an existing conversation - they can't create new ones per se. As a result, you need to pre-install your bot for the relevant users. There are two main ways to do this:

  1. Using Teams Policy - this requires an Admin, in the Teams Admin centre - see more here: https://docs.microsoft.com/en-us/microsoftteams/teams-app-setup-policies#install-apps . This option is the easiest, fastest, and most simple, but might not be available (e.g. no access to Teams Admin)
  2. The other option is to use the Microsoft Graph to auto-install the app for the user. To do this, here's the reference: https://docs.microsoft.com/en-us/graph/api/userteamwork-post-installedapps?view=graph-rest-1.0&tabs=http

Both of these approaches will work fine for an organisational app too - they don't need to be in the actual Teams Store

  • Related