Forum Discussion
Sarverizer
Aug 05, 2020Copper Contributor
Azure DevOps Service Hooks & Teams Incoming Webhooks
Hi everyone, I'm trying to determine how to utilize the Service Hooks in Azure DevOps so that we can tie into Teams via an incoming webhook to automatically post to a channel in Teams whenever a Pull Request is created.
When I run a test on the Azure side posting to the Incoming Webhook url from the Teams channel - I just get a 400/Bad Request
I assume the issue has to do with the format of the payload being sent from Azure and the format that the O365 connector is requiring - but I can't seem to find anything on this topic. Has anyone configured something like this or does anyone have some suggestions I can look into?
Thanks for your time!
Sarverizer Check this lab https://www.azuredevopslabs.com/labs/vstsextend/teams/
It will do what you need.
- What kind of data are you sending to the webhook? A card?
- SarverizerCopper Contributor
alexisconia thank you for the reply - we are trying to use a Service Hook that will trigger when a Pull Request has been created. It was our hopes that when that happens, it would hook into Teams and post to a given channel using the email link for said channel via that Outlook webhook. We'd be open to any alternatives providing we can automatically post to a channel when that Pull Request is created.
Thanks for your time,
Scott
- tiagocostaptLearn Expert
Sarverizer Check this lab https://www.azuredevopslabs.com/labs/vstsextend/teams/
It will do what you need.
- chadCopper Contributor
Bummer this does not work in this scenario:
tiagocostapt wrote:Sarverizer Check this lab https://www.azuredevopslabs.com/labs/vstsextend/teams/
It will do what you need.
Only Azure DevOps organizations in the same organization (AAD tenant) can be used to integrate with your Microsoft Teams account.
have a DevOps linked to a AAD that everyone is a guest. If we try to set this up it will only allow us to configure against a devops that is tied to our HOME AAD tenant 😞
- SarverizerCopper ContributorThis was exactly what we were looking for - thank you very much!
- SarverizerCopper Contributor
tiagocostapt thank you for this, I'll check it out and report back.