webUPI.requestPayment()
Request that the user creates a payment request to be used by the web app. This will return a UPI URI.
Method
async function requestPayment(args: RequestPaymentArgs): RequestPaymentResponse;
Parameters
interface RequestPaymentArgs {
amount: string | number;
payeeVPA?: string; // If web app wants the user to create from a specific UPI ID account.
transactionNote?: string;
}
Response
interface RequestPaymentResponse {
upiUri: string;
}
Code Example
await webUPI.enable();
const paymentRequest = await webUPI.requestPayment({
payeeVPA: 'yourvpa@bank',
amount: 1000,
transactionNote: 'Payment for services'
});
Last updated