I get this JSON back
stdClass Object ( [status] => stdClass Object ( [timestamp] => 2022-11-17T10:41:36.783Z [error_code] => 0 [error_message] => [elapsed] => 1 [credit_count] => 1 [notice] => ) [data] => stdClass Object ( [1] => stdClass Object ( [symbol] => w80iz51y4ka [id] => 1 [name] => omu2f57cwof [amount] => 1 [last_updated] => 2022-11-17T10:41:36.783Z [quote] => stdClass Object ( [GBP] => stdClass Object ( [price] => 0.436996948831 [last_updated] => 2022-11-17T10:41:36.783Z ) [LTC] => stdClass Object ( [price] => 0.201879205801 [last_updated] => 2022-11-17T10:41:36.783Z ) [USD] => stdClass Object ( [price] => 8977 [last_updated] => 2022-11-17T10:41:36.783Z ) ) ) ) )
I dont know how to handle this "stdClass Object". There are a lot in.
At postmen I get this result
{
"status": {
"timestamp": "2022-11-17T08:53:52.920Z",
"error_code": 0,
"error_message": null,
"elapsed": 1,
"credit_count": 1,
"notice": null
},
"data": {
"2": {
"symbol": "ymtwz9qdk3",
"id": 2,
"name": "9t5ci78gq36",
"amount": 1,
"last_updated": "2022-11-17T08:53:52.920Z",
"quote": {
"GBP": {
"price": 0.9733139411311549,
"last_updated": "2022-11-17T08:53:52.920Z"
},
"LTC": {
"price": 0.564631913659549,
"last_updated": "2022-11-17T08:53:52.920Z"
},
"USD": {
"price": 8956,
"last_updated": "2022-11-17T08:53:52.920Z"
}
}
}
}
}
I How can I convert this to an array in PHP? I test a lot also some solutions from other posts. But I am lost a bit.
Thanks and kind regards Markus