web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / How to traverse json o...
Power Automate
Unanswered

How to traverse json object dynamic properties in power automate

(0) ShareShare
ReportReport
Posted on by 12

I am using HTTP to fetch a POST request using SKUVault API which will send me All the its Items SKU as the Object Properties and those properties are dynamic and I want to traverse all of them
Here is the HTTP request I made and I cant seem to traverse it anyhow

Capture.PNG

 

Response is like this If I try to create a schema for it which create static name entries for those dynamic properties

 

{
 "Items": {
 "DAX123480": [],
 "028851034142": [],
 "680079732578": [],
 "J3001251": [],
 "032733973856": [],
 "B1235288": [],
 "B1235290": [],
 "Z8103": [],
 "Z1310": [],
 "Z8321": [],
 "Z2229": [],
 "K304024M": [],
 "662774014609": [],
 "Z1283": [],
 "Z7167": [],
 "Z7174": [],
 "Z7175": [],
 "887654023421": [
 {
 "WarehouseCode": "726",
 "LocationCode": "Z-B1-BA11-S1-B3",
 "Quantity": 1,
 "Reserve": false
 },
 {
 "WarehouseCode": "726",
 "LocationCode": "Z-B1-BA11-S3-B2",
 "Quantity": 1,
 "Reserve": false
 }
 ],
 "N22345699": [],
 "B123543W": [],
 "EEH4201693": [],
 "EEH4201707": [],
 "010343860575": [],
 "SXP1C202L3AWK": [],
 "819158024284": [],
 "H12363P": [],
 "CH23464001": [],
 "Z9560": [],
 "017541652643": [],
 "J3001501": [],
 "T5001115": [],
 "84691260233": [],
 "T80012359": []
 },
 "Errors": []
}

 Parse JSON Schema is this

{
 "type": "object",
 "properties": {
 "Items": {
 "type": "object",
 "properties": {
 "dynamicObject": {
 "type": "array"
 }
 }
 },
 "Errors": {
 "type": "array"
 }
 }
}

 

 Error occurred is following

 

CaptureError.PNG

 Api used: https://dev.skuvault.com/reference/getinventorybylocation

 

If anyone know about some similar forum as mine kindly address me to it or propose a valid solution for it, It would be a great help

Thank You

Categories:
  • VictorIvanidze Profile Picture
    13,083 on at

    Show your flow.

     

    Looks like you have to change

     

    items{...} to items[...]

  • geragt200 Profile Picture
    12 on at

    It just made things more difficult now now I have a string which I need to change into an array and now have to split in such a way which it should not disrupt my response pattern
    image.png

  • VictorIvanidze Profile Picture
    13,083 on at

    As you like, @geragt200. JSON assumes the array elements are between square brackets.

     

  • geragt200 Profile Picture
    12 on at

    Nope this doesn't look like what I am looking for I want to traverse them right now I can't traverse them in this state Its an array containing of a single string and which contains the whole data.

  • VictorIvanidze Profile Picture
    13,083 on at

    Try this:

    VictorIvanidze_0-1672838891846.png

     

  • geragt200 Profile Picture
    12 on at

    Nope still not working it just added more square brackets on its start and end

    image.png

  • VictorIvanidze Profile Picture
    13,083 on at

    My bad, sorry. What do you want to get as a result of handling "HTTP" action output?

  • geragt200 Profile Picture
    12 on at

    Some thing like this

    "Items": [
     {"27": [] },
     {"3240": []},
     {"3318": []},
     {"3324": []},
     {"3327": []},
    ]
  • VictorIvanidze Profile Picture
    13,083 on at

    Try this:

    concat(concat('[{',replace(substring(trim(string(outputs('Compose_0')?['items'])), 1, sub(length(trim(string(outputs('Compose_0')?['items']))), 2)),'],',']},{'),'}]'))
  • VictorIvanidze Profile Picture
    13,083 on at

    No joy?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
Mohsin Ali Profile Picture

Mohsin Ali 445

#2
11manish Profile Picture

11manish 345 Super User 2026 Season 2

#3
M Bilal Khan Profile Picture

M Bilal Khan 300

Last 30 days Overall leaderboard