I am trying to access some strings of a nested object.This object has a parent object with a variable name (Unix timestamp). The object I want to access is shown below as acmecorp and that value does not change
Here’s a small example response that I get:
[
{
"1679270400": {
"type": "cd",
"acmecorp": {
"onnetCalls": "0",
"offnetCalls": "0",
"totalDurationOnnet": "0",
"totalDurationOffnet": "0",
"date": "Mon, 20 Mar 2023 00:00:00 +0000"
}
},
"1679356800": {
"type": "cd",
"acmecorp": {
"onnetCalls": "0",
"offnetCalls": "1",
"totalDurationOnnet": "0",
"totalDurationOffnet": "11",
"date": "Tue, 21 Mar 2023 00:00:00 +0000"
}
},
"1679443200": {
"type": "cd",
"acmecorp": {
"onnetCalls": "0",
"offnetCalls": "3",
"totalDurationOnnet": "0",
"totalDurationOffnet": "179",
"date": "Wed, 22 Mar 2023 00:00:00 +0000"
}
}
}
]
Keep in mind that this is typically a response with several hundred objects, so manually accessing the strings under acmecorp isn’t really feasible.
Any help on this would be greatly appreciated, I’ve stumped myself on this. Thanks in advance!