PHP code example of sonofliberty / bitcoincom-rest
1. Go to this page and download the library: Download sonofliberty/bitcoincom-rest 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/ */
sonofliberty / bitcoincom-rest example snippets
use SonOfLiberty\BitcoinComRest\Client;
$client = new Client();
// get address details
$addressDetails = $client->address()->details('bitcoincash:qzs02v05l7qs5s24srqju498qu55dwuj0cx5ehjm2c');
// get slp token balances
$balances = $client->slp()->balancesForAddress('simpleledger:qz9tzs6d5097ejpg279rg0rnlhz546q4fsnck9wh5m');
// check 'examples' folder for more example code