PHP code example of changecoins / http-client

1. Go to this page and download the library: Download changecoins/http-client library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

changecoins / http-client example snippets




declare(strict_types=1);

namespace App;

use ChangeCoins\ClientFacade;
use ChangeCoins\Factory\RequestConfig;

...

$clientFacade = new ClientFacade(new RequestConfig('secretKey', 'publicKey'));
$client       = $clientFacade->createClient();



...

$balanceDto = new BalanceDto();
$balanceDto->setNonce(time());

$result = $client->getBalance($balanceDto)->toArray();