TFS Alert when label is created

163 Views Asked by At

Can I configure an alert when a TFS Label is created ? I don't find that option in the current predefined alerts. These are the ones I found:

Default Alerts

And I want when a label is created:

Label Created

Send an email notification.

2

There are 2 best solutions below

3
On BEST ANSWER

No, this is not possible using the standard Alert features.

0
On

I created my own solution! I don't know how much access you have to your on-premise TFS instance, but you need to be able to execute t-sql scripts against the TFS mssql database. My solution is here: https://github.com/Antebios/tfs-label-notification

And when anyone creates a TFSVC label I get an email alert that looks like this:

enter image description here

Basically, I created a database trigger to populate a table. I query that table and send an email out, then mark the label as sent. I also have a trigger to delete form that table just in case the label gets deleted. I wrote the service in .NET Core just in case anyone wants to convert it to run within a container. Let me know if this helps or not.