JSON Object Selection
Stack Overflow - https://stackoverflow.com/questions/66331247/access-nested-json
JavaScript
$(document).ready(function() {
var json = {
"data": [{
"name": "page_engaged_users",
"period": "day",
"values": [{
"value": 13521,
"end_time": "2021-02-22T08:00:00+0000"
}],
"title": "Daily Page Engaged Users",
"description": "Daily: The number of people who engaged with your Page. Engagement includes any click or story created. (Unique Users)",
"id": "231123/insights/page_engaged_users/day"
},
{
"name": "page_post_engagements",
"period": "day",
"values": [{
"value": 18963,
"end_time": "2021-02-22T08:00:00+0000"
}],
"title": "Daily Post Engagements",
"description": "Daily: The number of times people have engaged with your posts through like, comments and shares and more.",
"id": "231123/insights/page_post_engagements/day"
},
{
"name": "page_impressions_unique",
"period": "day",
"values": [{
"value": 347696,
"end_time": "2021-02-22T08:00:00+0000"
}],
},
],
}
var dataAll = json;
var dataSet = dataAll.data;
var rows = [],
data;
rows.push(dataSet[0].values[0].value)
console.log(rows)
});