PHP code example of fedeisas / dolar-blue

1. Go to this page and download the library: Download fedeisas/dolar-blue 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/ */

    

fedeisas / dolar-blue example snippets


'providers' => array(
    ...
    'Fedeisas\LaravelDolarBlue\LaravelDolarBlueServiceProvider',
)

'aliases' => array(
    ...
    'DolarBlue' => 'Fedeisas\LaravelDolarBlue\Facade\LaravelDolarBlue',
)

use Fedeisas\DolarBlue\DolarBlue;
use GuzzleHttp\Client;

$service = new DolarBlue(new Client);
$result = $service->get('DolarBlue'); // or $service->DolarBlue();
// returns
// array(
//   'buy' => '10.15',
//   'sell' => '10.55',
//   'timestamp' => 1399080004
// )

$result = $service->LaNacion();
$result = $service->DolarBlue();
$result = $service->BlueLytics();