taiwan-pay / chb-payment
Payment library for CHB bank in Taiwan.
0.1
2019-03-16 07:37 UTC
Requires
- php: ^7.1
Requires (Dev)
- phpunit/phpunit: ^6.1
This package is not auto-updated.
Last update: 2024-12-16 16:22:51 UTC
README
Payment library for CHB bank in Taiwan. It use simply web api for CHB bank.
Install
$ composer require taiwan-pay/chb-payment
Usage
- initiate the payment
use TaiwanPay\CHBPayment; $payment = new CHBPayment([ 'macKey' => $macKey, 'key' => $key, 'merID' => $merID, 'MerchantID' => $MerchantID, 'TerminalID' => $TerminalID, 'MerchantName' => $MerchantName ], false);
- authenticate an order
// get auth data and render form by yourself $payment->auth($orderNumber, $amount, $type, $resUrl, $createTime, false); // get auth form and render it $payment->auth($orderNumber, $amount, $type, $resUrl, $createTime, true);
- search an order
// get search data and render form by yourself $payment->search($orderNumber, $amount, $resUrl, false); // get search form and render it $payment->search($orderNumber, $amount, $resUrl, true);
Note: All the response will be
POST
to$resUrl
from bank.
License
MIT