Not sure what to do, I have tried everything I can think of and search up. Now I don't know much about json, so I could be missing something. I am trying to read this multilevel json data.
{
"status" : "success",
"data" : {
"network" : "BTCTEST",
"txs" : [
{
"txid" : "13641a6bd0d0f9c166756bcf37d4f1d0bb435eba7803233b14e8d9aa1f58395d",
"from_green_address" : true,
"time" : 1499901470,
"confirmations" : 5,
"amounts_received" : [
{
"recipient" : "2Mxwy1ZUPJMcpiPath6HVzguyXdt6cMKmuQ",
"amount" : "0.00080000"
}
],
"senders" : [
"2N9fTBM2CmC6kyLHdqk8UwUvaz1DBZRQYcX"
],
"confidence" : 1.0,
"propagated_by_nodes" : null
}
]
}
}
I am trying to get the data from data>txs>amounts_received>amount, but it keeps coming up as NULL. I can't seem to find anyway to fix this, but currently my code looks like this:
var_dump($newAddressInfo->data->txs[0]->amounts_received->amount);
Can anyone help with this issue? Thanks!