So, I was working on gather data from a “streams” request, and as I was working through gathering the data, I ran into a road block. The data is structured like this
{“data”:[{“id”:“user-id”,“login”:“u-login”,“display_name”:“ds-name”,“type”:"",“broadcaster_type”:“partner”,“description”:“User-Descripton “,“profile_image_url”:“profile-url”,“offline_image_url”:“offline-url”,“view_count”:502504},{“id”:“user-id”,“login”:“u-login”,“display_name”:“ds-name”,“type”:””,“broadcaster_type”:“partner”,“description”:“Eat. Sleep. Stream. Repeat. #KeepWinning”,“profile_image_url”:“url-profile”,“offline_image_url”:“off-url”,“view_count”:106110}]}
Normally, I would parse this data in an object, then do data.id, but in this data, the second layer of json is inside a pair of [ ], how do you access, for example, the display_name?