MS Teams integration (set up subscriptions for incoming messages)

We’re looking for some assistance with the MS Teams integration. We can’t figure out how to set up the subscriptions for incoming messages; graph sends a response to the initialisation call and expects a verification code from that that it included in its response back. After this is done it sends the notification data to that same endpoint. We can’t figure out how to respond to these separate types of responses to the same endpoint in Bubble.

/users/{id}/chats/getAllMessages - this is the resource we want to get notifications for.

MS Teams documentation: Receive change notifications through webhooks - Microsoft Graph | Microsoft Learn

@ndgonsal ,
I am working on the same thing at the moment and have not found a solution yet. From the research that I’ve done, my sneaking suspicion is that Bubble is not capable of performing the verification response that MS requires for the subscription. Have you been able to make any progress?

Hello @tl11 @ndgonsal im facing the same issue, did you fond a solution please ? thank s!

@Alter345 ,

Currently, there is no functionality in bubble to perform a custom response to a webhook. I was able to use Make.com to perform the necessary workflow to add the subscription. I am now working on giving my application its own authentication with MS so that it can perform all the necessary backend workflows when the user is not logged in.

If you would like assistance using Make.com to set it up, DM me and I can walk you through it.
Essentially, I have my Bubble plugin that calls the MS “Create Subscription” endpoint with the response URL being the webhook in Make.com. It runs through a filter in Make to decide if its a subscription verification or a notification and then will either send the appropriate response to verify the subscription, or make the necessary requests based on the notification.

@tl11 Thanks for your reply :slight_smile:
interisting, I finished building the same type of scenario on make that includes, HTTP module and webhook in fact. I have one question though : Did you get to use the “watch events” module from microsoft on outlook ? Im asking you this because i couldn’t set it up because the module does not gather all my outlook calendar IDs. Do you have the same issue. So while waiting, i decided to go with other process i attached in this post. It would be interisting for me to know if your scenrio is better or not (since i have to duplicate this one as many user as i have ^^thanks


Still trying to figure out! But let us know if you do!