$ReleaseBody = @{
Id = $Project.Id
ProjectId = $Project.Id
ChannelId = $Channels.Items.Id
Version = $VERSION
SelectedPackages = @( @{
StepName = $DeploymentProcess.Steps.Name[0]
Version = $dt.Items.Version
})
} | ConvertTo-Json
我正在查询通过$DeploymentProcess
返回一个或多个StepName的API,我想始终为POST选择第一个。如果有多个步骤,则上述方法可以正常工作,但只有一个步骤时,上述方法可以正常工作。有想法吗?