azure-devopsazure-pipelinesdevopspower-automate

Power-Automate: Azure DevOps connector - when a build completes trigger output "Parameters" is always empty


I am working on a teams notifications automation for my pipeline. I would like to output details of this pipeline to my teams channel when build completes successfully. Every needed output from AzureDevOps connector works fine (BuildId, Url, SourceBranch,...), except "parameters"

Power Automate flow

After this flows get triggered I get a message to my teams chat like this one

Teams Message

Right now I am using a basic pipeline that echoes parameter "line"

Pipeline parameters

Here is the run of the pipeline

Run of the pipeline

I am expecting to see parameters of the pipeline in my teams chat. (Am I misunderstanding this output called "Parameters"?)


Solution

  • If you check the run history of the Power Automate workflow, you will find it doesn't contain the pipeline parameter for When a build completes. Hence, you cannot get the parameter in next Post message in a chat or channel action.

    After When a build completes, you can add a HTTP action, to get the devops build result, the url like https://dev.azure.com/{org}/{project}/_apis/build/builds/{buidid}?api-version=6.0. You can get {buildid} from previous When a build completes action. It contains the templatesparameters line in the response. Then you can use it in action Post message in a chat or channel.