nitish24p / react-native-upi

A tiny module for Adding payments via UPI in your react native apps ❤️
MIT License
72 stars 29 forks source link

No apps can perform this action. #51

Open koreahn opened 10 months ago

koreahn commented 10 months ago

Hello. I am developing an app with react-native-upi. I am testing multi real devices and emulator. Some devices are working fine. However, on some devices, the call to "RNUpiPayment.initializePayment" fails to list the installed UPI apps and displays the message below.

I have paytm, phonepe, google pay app installed on my test device. I don't think it's an android version issue, some devices work with version 13 and some don't. The difference is that the devices that don't list the UPI app only have the UPI app installed, not logged in.

If you know anything, please help me. Thanks. Below is the source code.

const init = () => {
  try {
    RNUpiPayment.initializePayment(
      {
        vpa: 'upi_id@ybl',
        payeeName: 'my payee name',
        amount: '1',
        transactionRef: 'aasf-332-aoei-fn',
        transactionNote: 'for food',
      },
      successCallback,
      failureCallback,
    );
  } catch (e) {
    console.error('Error:', e);
  }
};

function successCallback(data) {
  // do whatever with the data
  console.log('success', data);
}

function failureCallback(data) {
  // do whatever with the data
  console.log('error', data);
}
getsettalk commented 10 months ago

in my device working fine with paytm,... other apps not working like google pay

Dhaval1905 commented 9 months ago

I am also facing same error.