1. Go to this page and download the library: Download phalconvee/laravel-paga 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/ */
return [
/**
* API Key From Paga Dashboard
*/
'apiKey' => env('PAGA_HMAC_API_KEY'),
/**
* Public Key From Paga Dashboard
*/
'publicKey' => env('PAGA_PUBLIC_KEY'),
/**
* Secret Key / Credentials From Paga Dashboard
*/
'secretKey' => env('PAGA_SECRET_KEY')
];
use Phalconvee\Paga\Facades\Paga;
class MyExampleController extends Controller
{
public function __construct()
{
Paga::setTest(true); // passing false (boolean) sets environment to live.
}
}
/**
* This method generates a unique secure cryptographic hash token to use as transaction reference.
* @returns string
*/
Paga::getTransactionReference();
/** Alternatively, use the helper */
paga()->getTransactionReference();
/**
* This method returns list of banks integrated with Paga.
* @returns array
*/
Paga::getBanks();
/** Alternatively, use the helper */
paga()->getBanks();
/**
* This method returns list of merchants integrated with Paga.
* @returns array
*/
Paga::getMerchants();
/** Alternatively, use the helper */
paga()->getMerchants();
/**
* This method returns list of merchants services registered on Paga.
* @returns array
*/
Paga::getMerchantServices();
/** Alternatively, use the helper */
paga()->getMerchantServices();
/**
* This method returns operation status per transaction.
* @returns array
*/
Paga::getOperationStatus();
/** Alternatively, use the helper */
paga()->getOperationStatus();
/**
* This method returns mobile operators on Paga.
* @returns array
*/
Paga::getMobileOperators();
/** Alternatively, use the helper */
paga()->getMobileOperators();
/**
* This method allows you to transfer funds from a variety of sources via Paga.
* @returns array
*/
Paga::moneyTransfer();
/** Alternatively, use the helper */
paga()->moneyTransfer();
/**
* This method allows you to make bulk money transfer via Paga.
* @returns array
*/
Paga::moneyTransferBulk();
/** Alternatively, use the helper */
paga()->moneyTransferBulk();
/**
* This method allows you to purchase airtime via Paga.
* @returns array
*/
Paga::airtimePurchase();
/** Alternatively, use the helper */
paga()->airtimePurchase();
/**
* This method allows you to get account balance on Paga.
* @returns array
*/
Paga::accountBalance();
/** Alternatively, use the helper */
paga()->accountBalance();
/**
* This method allows you deposit funds into any bank account.
* @returns array
*/
Paga::depositToBank();
/** Alternatively, use the helper */
paga()->depositToBank();
/**
* This method allows to validate deposit to bank via Paga.
* @returns array
*/
Paga::validateDepositToBank();
/** Alternatively, use the helper */
paga()->validateDepositToBank();
/**
* This method allows to make payments to registered merchants on Paga.
* @returns array
*/
Paga::merchantPayment();
/** Alternatively, use the helper */
paga()->merchantPayment();
/**
* This method gets merchant Paga transaction history.
* @returns array
*/
Paga::transactionHistory();
/** Alternatively, use the helper */
paga()->transactionHistory();
/**
* This method gets merchant recent Paga transaction history (last 5 records).
* @returns array
*/
Paga::recentTransactionHistory();
/** Alternatively, use the helper */
paga()->recentTransactionHistory();
/**
* This method allows aggreagtor organisations create sub organisations on Paga.
* @returns array
*/
Paga::onBoardMerchant();
/** Alternatively, use the helper */
paga()->onBoardMerchant();
/**
* This method creates customer on Paga.
* @returns array
*/
Paga::registerCustomer();
/** Alternatively, use the helper */
paga()->registerCustomer();
/**
* This method validates customer created on Paga.
* @returns array
*/
Paga::validateCustomer();
/** Alternatively, use the helper */
paga()->validateCustomer();