Generate QR
To make a payment through the Bank Platform, it is necessary to create a QR String for connecting the bank to use the Mobile Banking app to make the connection. Currently, we can connect to 3 banks in Laos such as: BCEL, Joint Development Bank (JDB), Indochina Bank (IB). The way to connect to create a QR is as follows
Bank API URL
1. Indochina Bank IB

IB_URL
https://payment-gateway.lailaolab.com/v1/api/payment/generate-ib-qr
2. BANQUE POUR LE COMMERCE EXTERIEUR LAO PUBLIC (BCEL)

BCEL_URL
https://payment-gateway.lailaolab.com/v1/api/payment/generate-bcel-qr
3. Joint DEVELOPMENT BANK (JDB)

JDB_URL
https://payment-gateway.lailaolab.com/v1/api/payment/generate-jdb-qr
4. LAO DEVELOPMENT BANK (LDB)

LDB_URL
https://payment-gateway.lailaolab.com/v1/api/payment/generate-ldb-qr
How to use
Request
API Options | Details |
---|---|
method | POST |
url string | url of the service bank |
Header Parameters | Details |
---|---|
secretKey string | Your secretKey after being approved can be taken at Key Service |
Content-Type string | The media type of the resource being sent must be set to "application/json" |
Field | Type | Required | Description |
---|---|---|---|
amount | Number | Yes | The amount to be paid for the transaction. |
description | String | Yes | payment description's purpose () |
tag1 | String | No | Custom field #1 for your internal reference. |
tag2 | String | No | Custom field #2 for your internal reference. |
tag3 | String | No | Custom field #3 for your internal reference. |
Nodejs
const axios = require('axios');
let data = JSON.stringify({
"amount": 1,
"description": "Example Description" // NOTE: BCEL description is not support for lao,thai charater
let config = {
method: 'post',
maxBodyLength: Infinity,
url: 'BCEL_URL', // your selected bank
headers: {
'secretKey': 'secretKey', // use testKey instead if you're not KYC
'Content-Type': 'application/json'
},
data: data
axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});
⚠️ Note:
secretKey : use testKey instead if you're not KYC.
description : For BCEL BANK now does not support description in Thai/lao charater
Response
Key | Details |
---|---|
message string | The response message from API call |
transactionId string | The id of transaction |
qrCode string | The QR string of the transaction |
link string | Deeplink to access to each bank's app (IB: Can't access app) |
application/json
{
"message": "SUCCESSFULLY",
"transactionId": "8cc876b4-a4af-4886-81f1-3890453eb656",
"qrCode": "00020101021133730004BCEL0106ONEPAY0216mch6542c0373ede30314202403271909590513CLOSEWHENDONE53034185405100005803VTE6002LA625305368cc876b4-a4af-4886-81f1-3890453eb5560809Buy Pants630440FF",
"link": "onepay://qr/00020101021133730004BCEL0106ONEPAY7216mch6541c0373ede30314202403271909590513CLOSEWHENDONE53034185405100005803VTE6002LA625305368cc876b4-a4af-4886-81f1-3890453eb5560809Buy Pants630440FF"
}