[英]Logic App - Expression to get a particular substring from a json
我已經完成了 Logic App 中的一項任務:
{
"headers": {
"Connection": "close",
"Content-Type": "application/json"
},
"body": {
"systemAlertId": "....",
"endTimeUtc": null,
"entities": [
{
"$id": "us_1",
"hostName": "...",
"azureID": "someID",
"type": "host"
},
{
"$id": "us_2",
"address": "fwdedwedwedwed",
"location": {
"countryCode": "",
},
"type": "ip"
},
],
}
}
我需要初始化一些名為 resourceID 的變量,其中包含從上面的示例中讀取的值someID 。
值someID將始終在 Entities 數組的第一個成員中找到,在這種情況下我想需要先使用 function
知道 Initial 變量的表達式應該是什么樣子嗎?
謝謝
要引用或訪問 JavaScript Object 表示法 (JSON) 內容中的屬性,您可以使用Parse JSON操作為這些屬性創建用戶友好的字段或標記。 這樣,當你為邏輯應用指定輸入時,你可以從動態內容列表中 select 這些屬性。 對於此操作,您可以提供 JSON 架構或從示例 JSON 內容或負載生成 JSON 架構。
通過 object 中可用的 JSON 中的信息,您可以更輕松地訪問它。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.