Im learning coinbase api and messing around with php. I cant seem to add data as variable from array as array is private. How can i set private values as variable?
$coinbaseconf = Configuration::apiKey($coinbaseapi, $coinbasesecret); $client = Client::create($coinbaseconf);
returns
Coinbase\Wallet\Value\Money Object ( [amount:Coinbase\Wallet\Value\Money:private] => 5567.17 [currency:Coinbase\Wallet\Value\Money:private] => GBP )
if i try:
$var1 = $btcusdsellprice->amount;
Get error
Fatal error: Uncaught Error: Cannot access private property Coinbase\Wallet\Value\Money::$amount in /var/www/html/xxx/xxx.php:22 Stack trace: #0 {main} thrown in /var/var/www/html/xxx.php on line 22