Hi, Below is the json schema i am using in my Parse json connection & Json body sample. The parse works with the schema below , but i am unable to extract the addressPrefixes by name.
E.g I need to parse the json and get the addressPrefixes under a property with name : VM1 .
How to acheive this using power automate.
{
"type": "object",
"properties": {
"statusCode": {
"type": "integer"
},
"headers": {
"type": "object",
"properties": {
"Cache-Control": {
"type": "string"
},
"Pragma": {
"type": "string"
},
"Transfer-Encoding": {
"type": "string"
},
"Vary": {
"type": "string"
},
"x-ms-request-id": {
"type": "string"
},
"x-ms-correlation-request-id": {
"type": "string"
},
"x-ms-arm-service-request-id": {
"type": "string"
},
"Strict-Transport-Security": {
"type": "string"
},
"Server": {
"type": "string"
},
"x-ms-ratelimit-remaining-subscription-reads": {
"type": "string"
},
"x-ms-routing-request-id": {
"type": "string"
},
"X-Content-Type-Options": {
"type": "string"
},
"Date": {
"type": "string"
},
"Content-Type": {
"type": "string"
},
"Expires": {
"type": "string"
}
}
},
"body": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"id": {
"type": "string"
},
"type": {
"type": "string"
},
"changeNumber": {
"type": "string"
},
"cloud": {
"type": "string"
},
"values": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"id": {
"type": "string"
},
"serviceTagChangeNumber": {
"type": "string"
},
"properties": {
"type": "object",
"properties": {
"changeNumber": {
"type": "string"
},
"region": {
"type": "string"
},
"state": {
"type": "string"
},
"networkFeatures": {
"type": "array",
"items": {
"type": "string"
}
},
"systemService": {
"type": "string"
},
"addressPrefixes": {
"type": "array",
"items": {
"type": "string"
}
}
}
}
},
"required": [
"name",
"id",
"serviceTagChangeNumber",
"properties"
]
}
},
"nextLink": {
"type": "string"
}
}
}
}
}
My Json looks like below
{
"name": "VM01",
"id": "VM01",
"properties": {
"changeNumber": 1,
"region": "USWest",
"regionId": 3,
"platform": "Azure",
"systemService": "VM",
"addressPrefixes": [
"xx.xx.xx.xx/32",
"xx.xx.xx.xx/32"
],
"networkFeatures": null
}
},
{
"name": "VM02",
"id": "VM02",
"properties": {
"changeNumber": 2,
"region": "USEast",
"regionId": 4,
"platform": "Azure",
"systemService": "VM",
"addressPrefixes": [
"xx.xx.xx.xx/32",
"xx.xx.xx.xx/32"
],
"networkFeatures": null
}
}