Power automate Http request body as Remote Execution Object,如何从输入参数中检索特定字段

Power automate Http request body as RemoteExecutionObject, How to retreive particualr field from Input argument

我有 Power 自动化,运行 作为动态的 webhook,即触发器是 HTTP 请求。

一旦这个请求 运行 它包含主体作为 RemoteExecutionObject。

下面的例子

{
  "BusinessUnitId": "eedd1dcd-1318-e611-80d3-005056936c69",
  "CorrelationId": "8385868f-4fa4-42a0-9c83-6b63a5cd4774",
  "Depth": 2,
  "InitiatingUserAzureActiveDirectoryObjectId": "00000000-0000-0000-0000-000000000000",
  "InitiatingUserId": "91ff1dcd-1318-e611-80d3-005056936c69",
  "InputParameters": [
    {
      "key": "Target",
      "value": {
        "__type": "Entity:http://schemas.microsoft.com/xrm/2011/Contracts",
        "Attributes": [
          {
            "key": "crm_abc",
            "value": null
          },
......
......
}

我希望从 Power automate 中的 InputParameetrs 中检索特定字段及其值。

Here is one close to example mentioning how it can be achieved. But it is still not clear

有没有人有同样的想法。

使用变量解决了这一特殊挑战,并且一次使用 array/object 个变量。

例如:首先从 Json

中检索到 InputParameters 作为数组
triggerBody()['InputParameters']

然后使用索引 0 以便我获得作为对象的完整 InputParameters

 triggerBody()['InputParameters'][0]

然后得到值数组如下

triggerBody()['InputParameters'][0]['value']['Attributes']

然后属性为数组

triggerBody()['InputParameters'][0]['value']['Attributes']

注意我们可以直接用上面的表达式检索属性。

现在为了从 Attributes 数组中获取特定字段,我使用了 power automate 中的过滤器数组操作并将其用作

我们可以用类似的方式检索各个字段