Provide a Teams API To send direct messages to users
Currently, the only way to send messages is to post a message on a channel in a team. It would be great if there could be an API to send a direct message to the users. Please let me know if it already exists, because I could not find any such method in the chat object here :
We now support proactive messaging, allowing bots to send 1:1 messages to people who have the app installed. And Graph now provides an API to install Teams apps for users: https://docs.microsoft.com/en-us/graph/api/user-add-teamsappinstallation?view=graph-rest-beta&tabs=http
Jan Donyada commented
Anyone able to find a workaround for sending proactive messages to users in personal scope without installing or user sending a DM first?
@nick based on what you're saying, we can install the app to users using https://docs.microsoft.com/en-us/graph/api/user-add-teamsappinstallation?view=graph-rest-beta&tabs=http
How do we retrieve the corresponding list of conversation IDs to post the message?
I was able to figure out how to do this and implement it in node-js for Slack in 10 minutes. We're talking a simple https-request with a token to authenticate:
What's stopping MS who has access to some of the very best software engineers, from implementing something so simple, is unfathomable to me. I mean, this is such a basic feature and should be very easy to fix.
Nick, could you please publish the exact method to send message to a specific user?
Is there any update seems to be more raise in demand for this api.
Tzachi Hakmon commented
Hi Nick it seems like we need the ChannelAccount id of the user for sending pro-active message. The problem is that the only ways to get the channelAccount Id is from the current turnContext , but what if i want to Create conversation with a user which haven't just send me a message ? Hoe could i get his Channel Account Id ?
Any new updates ? this feature is so important
Kumar, Hemant A. commented
@Nick : I am working on a project to migrate code from UCMA to MS-Team.
Through MS-Graph API I am not able to send direct message to MS-Team user. This is the basic functionality.
Not sure what is stopping Microsoft engineer to give the functionality. You ppl are giving lot of stress :(