payplus-ipg
v1.0.1
Published
NPM for PayPlus IPG
Downloads
146
Maintainers
Readme
PayPlus IPG Plugin
PayPlus IPG is a simple and flexible payment integration for developers looking to integrate Internet Payment Gateway (IPG) by PayPlus into their Javascript applications. With support for multiple payment methods, tokenization, and both sandbox and live environments, this package helps you securely handle transactions with ease.
Features
- Card Transactions — Visa, Mastercard and American Express
- Bank Transfer — Enable payments through bank transfers in Sri Lanka.
- Saved Card Feature (Tokenization) — Offer your customers the convenience of securely saving their card details for future transactions.
- Facilitate transactions via Frimi, Q+, Sampath Vishwa, iPay and Lanka QR
Installation
npm install payplus-ipg
Usage
package
const PayplusIpg = require('payplus-ipg')
const dp = new PayplusIpg.Init({
signature: signature,
dataString: encoded_payload,
stage: 'DEV',
container: 'card_container'
})
//popup IPG
dp.doInAppCheckout().then((data) => {
console.log('client-res', JSON.stringify(data))
}).catch((error) => {
console.log('client-error', JSON.stringify(error))
})
//open IPG inside page component
dp.doInContainerCheckout().then((data) => {
console.log('client-res', JSON.stringify(data))
}).catch((error) => {
console.log('client-error', JSON.stringify(error))
})