Announcement

Collapse
No announcement yet.

HTTP Listener - JSON Array

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • HTTP Listener - JSON Array

    I have a channel with an HTTP Listener source and I need to create an HL7 message from the JSON being sent. Does anyone have an example of how I can iterate through multiple child records being sent in the JSON message? I have not worked with JSON before so I apologize if this question is ridiculously simple. Below is a similar example of what this channel would be receiving. Since there would be an array sent, I would like to have a for each loop somehow but not sure how to grab the values. Thank you in advance for any assistance.

    {
    "id": "12345",
    "location": "LMNOP",
    "visitList":
    [{
    "field01": "aaaaa",
    "field02": "bbbbb",
    "field03": "ccccc",
    "field04": "ddddd"
    },
    {
    "field01": "eeeee",
    "field02": "fffff",
    "field03": "ggggg",
    "field04": "hhhhh"
    },
    {
    "field01": "iiiii",
    "field02": "jjjjj",
    "field03": "kkkkk",
    "field04": "lllll"
    }]
    }
Working...
X