PHP code example of nusagates / larapay

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

    

nusagates / larapay example snippets


return [
    'va'        => env('LARAPAY_VA', '000000XXXXXXXXXX'),
    'api_key'   => env('LARAPAY_API_KEY', 'SANDBOXXXX-XXXX-XXX'),
    'mode'      => env('LARAPAY_MODE', 'sandbox'), // sandbox | production
    ...
];

use Nusagates\Larapay\Vendors\iPaymu\Ipaymu;

public function index(Ipaymu $iPaymu)
{
    return $iPaymu->getBalance();
}


use Nusagates\Larapay\Facades\Ipaymu;

Ipaymu::getBalance();

$iPaymu->getBalance();

$iPaymu->getHistory();
bash
php artisan vendor:publish --tag=larapay-config