Bank payment
// The sample request payload that needs to encrypt
{
clientId: '2335689b-7a4d-420a-9cc0-f5d765a96967',
amount: 1,
accountId: '8ebzpaLqdqtlgXB53LemsalJ88ZpWMiwrKnkZ',
cart: [
{
id: '2763',
name: 'Data cable',
price: 1,
quantity: 1,
localAmount: 1,
localCurrency: 'USD'
}
],
stockId: 'd56b7410-4d39-4b32-a055-0828e9ab1ce5',
offerId: '4e3c59b0a14519ee6d620be63241bd71',
merchantStoreCurrency: 'USD',
hostedPageId: ''
shippingAddress{
"firstname": "",
"lastname": "",
"phoneNo": "",
"address1": "",
"address2": "",
"state": "",
"city": "",
"zipcode": "",
"country": "",
"landmark": "",
"email": ""
}
}
// clientId: The RKFL merchant id
// amount: cart total
// account Id: the merchant bank account id where the fund is to be transferred
// stockId: shopper connected bank account identifier
// offerId: merchant's unique identifier
// The key "data" should generate from the below way.
export const data = async (toEncrypt, publicKey) => {
const buffer = Buffer.from(toEncrypt);
const encrypted = crypto.publicEncrypt(publicKey, buffer);
return encrypted.toString('base64');
};Headers
Name
Type
Description
Request Body
Name
Type
Description
Last updated
Was this helpful?