I am able to create a work item using Microsoft Flow in Azure DevOps although I have questions on that as well. But first:
- How do I update an existing work item if someone replies to the email that they previously sent to create the work item? I dont know what is the best way to find whether an item already exists but the logic I have on mind is checking whether the subject line contains "RE:" and then based on that either create a new work item or update existing. With updating existing, I am having issues in finding the existing work item because it asks me ID but all I have is subject line to look up the ID and use that ID.
Also, for the email notifications sent from DevOps, how do I modify the "from" email so that it always gets sent to the email that I am using to trigger Microsoft Flow?
If there is a better option to create/update work items using emails, I am open to that as well.
HI @adityabajaj ,
Do you want to check if a record already exists in Azure DevOps to either update an existing work item or create a new one?
I don’t have Azure DevOps to test this issue, so I have created a flow based on SharePoint list for your reference.
In the following scenario, I am going to check if the incoming email’s subject exists in the list, if yes, update the Date column with email received time, if no, create a new one.
In the flow, I initialized an Array variable named as SubjectTest.
Under action Get items, add Apply to each, then the action Append to array variable within the loop. Set its value as dynamic content Title.
Add a Condition to check if the variable SubjectTest contains Subject.
Under if yes branch, add another Condition 2 to check if the email subject is equal to Title. If yes, update item.
Under if no branch, add action Create item to create a new item.
Images for your reference.
Hi @adityabajaj ,
Have you made a test on your side?
Could it be a reference for you?
Three Super User rank tiers have been launched!
Features releasing from October 2020 through March 2021
We've updated and improved the layout and uploading format of the Power Automate Cookbook!
Fill out a quick form to claim your user group badge now!