I assume you are asking "how do i convert a JSON string to a BrightScript data structure?". That's very easy actually and rather pleasant - just use
parseJSON() function - and
formatJSON() in the opposite direction. Here is example on going forth and back:
Brightscript Debugger> bs = [ { url: "http://me.com/x-384.mp4", bitrate: 384, quality: false, contentid: "x-384" }, { url: "http://me.com/x-2500.mp4", bitrate: 2500, quality: true, contentid: "x-1500" } ]: ? bs
<Component: roArray> =
[
<Component: roAssociativeArray>
<Component: roAssociativeArray>
]
Brightscript Debugger> js = formatJSON(bs): ? js
[{"bitrate":384,"contentid":"x-384","quality":false,"url":"http://me.com/x-384.mp4"},{"bitrate":2500,"contentid":"x-1500","quality":true,"url":"http://me.com/x-2500.mp4"}]
Brightscript Debugger> js2bs = parseJSON(js): ? js2bs
<Component: roArray> =
[
<Component: roAssociativeArray>
<Component: roAssociativeArray>
]