getAllUpiApps method
Retrieves a list of UPI apps available on the device.
Returns: A Future that completes with a list of UPI apps.
Implementation
Future<List<UpiApp>> getAllUpiApps() async {
final List<Map>? apps = await _channel.invokeListMethod<Map>('allUPIApps');
List<UpiApp> upiIndiaApps = [];
apps?.forEach((Map app) {
if (app['packageName'] == "in.org.npci.upiapp" ||
app['packageName'] == "com.google.android.apps.nbu.paisa.user" ||
app['packageName'] == "com.phonepe.app" ||
app['packageName'] == "in.amazon.mShop.android.shopping" ||
app['packageName'] == "net.one97.paytm"
///Coming soon
// app['packageName'] == "com.freecharge.android" ||
// app['packageName'] == "com.axis.mobile" ||
// app['packageName'] == "com.infrasofttech.centralbankupi" ||
// app['packageName'] == "com.infra.boiupi" ||
// app['packageName'] == "com.lcode.corpupi" ||
// app['packageName'] == "com.lcode.csbupi" ||
// app['packageName'] == "com.dbs.in.digitalbank" ||
// app['packageName'] == "com.equitasbank.upi" ||
// app['packageName'] == "com.mgs.hsbcupi" ||
// app['packageName'] == "com.csam.icici.bank.imobile" ||
// app['packageName'] == "com.lcode.smartz" ||
// app['packageName'] == "com.mgs.induspsp" ||
// app['packageName'] == "com.msf.kbank.mobile" ||
// app['packageName'] == "com.hdfcbank.payzapp" ||
// app['packageName'] == "com.Version1" ||
// app['packageName'] == "com.psb.omniretail" ||
// app['packageName'] == "com.rblbank.mobank" ||
// app['packageName'] == "com.lcode.ucoupi" ||
// app['packageName'] == "com.ultracash.payment.customer" ||
// app['packageName'] == "com.YesBank" ||
// app['packageName'] == "com.bankofbaroda.upi" ||
// app['packageName'] == "com.myairtelapp" ||
// app['packageName'] == "com.dreamplug.androidapp" ||
// app['packageName'] == "com.sbi.upi"
) {
// || app['packageName']== "com.whatsapp"
// || app['packageName']== "com.whatsapp.w4b") {
upiIndiaApps.add(UpiApp.fromMap(Map<String, dynamic>.from(app)));
}
});
return upiIndiaApps;
}