Let's demonstrate simple usage with ... example:
import { RavePay } from 'flutterwave-node-sdk'
export const rave = RavePay(
RAVE_PUBLIC_KEY,
RAVE_SECRET_KEY,
RAVE_IS_PRODUCTION
)
const raveData = {
payment_type: 'mobilemoneygh',
network: transactionSchema.network,
voucher: transactionSchema.voucher,
is_mobile_money_gh: 1,
currency: 'GHS',
country: 'GH',
amount: amount.toString(),
email: email,
phonenumber: phone,
firstname: '',
lastname: '',
IP: '',
txRef: 'APP-NAME' + Date.now(),
redirect_url: '',
meta: [],
device_fingerprint: '',
}
let res = await rave.initPayment(raveData)