azhar1038 / UPI-Plugin-Flutter

Flutter Plugin to do UPI transaction using different apps like PhonePe, Google Pay, PayTM etc.
MIT License
53 stars 38 forks source link

How to send money using bank account instead of UPI ID? #27

Closed dinesh4official closed 4 years ago

dinesh4official commented 4 years ago

Hi,

Thanks for the package. I need to transfer the money to my customers using bank account number and IFSC code instead UPI id. Can you let me know how to achieve this using this package.

Thanks in Advance, Dinesh

azhar1038 commented 4 years ago

This plugin is based on intent calls to UPI Apps following NPCI UPI Linking Specification. So it's not possible for this plugin to send using bank account number. I would suggest you to go for any payment aggregators like RazorPay which is more secure and allows option other than UPI for payment.

dinesh4official commented 4 years ago

@mdazharuddin1011999 thanks but two week before. it was working perfect with the following format.

receiverUpiId: "$accountNumber@$ifscNumber.ifsc.npci",

This week only it throws error as UpiIndiaInvalidParametersException (INVALID_PARAMETERS: Incorrect UPI ID provided)

azhar1038 commented 4 years ago

Oh! It's because in the 2.2.0, I am using regex to verify the upi id. I didn't know about this hack! I will implement this as a feature if it really works. If it's urgent for you, you may switch back to stable version temporarily. Thanks for letting me know!

dinesh4official commented 4 years ago

@mdazharuddin1011999 will give a try.. it may help for others..

azhar1038 commented 4 years ago

You are right! It does work but not all UPI Apps can handle this like Mi Pay.

azhar1038 commented 4 years ago

I have published the new version which supports passing bank account nuumber and IFSC code. Check in pub

You can use getIdFromAccount(String accountNumber, String ifscCode) method which does the extra work for you!

dinesh4official commented 4 years ago

@mdazharuddin1011999 , thanks. did you checked whether it is working at your end? Because, it is not working for the past week.

azhar1038 commented 4 years ago

Yes. I was able to transfer. I tested the transaction through PhonePe only. Although Google Pay, PhonePe and BHIM, all were able to process the intent call.

dinesh4official commented 4 years ago

okay thanks i will give a try to this

dinesh4official commented 4 years ago

@mdazharuddin1011999 thanks, it navigates to the BHIM applications but the payment is always failed via my application.

azhar1038 commented 4 years ago

Payment fails when using account number or even when using UPI ID? Are you sure it is not from bank side?

dinesh4official commented 4 years ago

yes, i am sure that it is not from bank side. I have done the same transaction from PhonePe instead via my application and the transaction is success. Payment fails only when using account number. Bu two/three weeks back it works perfectly.

azhar1038 commented 4 years ago

Maybe they can't process this type of transaction anymore. In my case PhonePe, Google Pay was able to complete the transaction while MiPay couldn't understand the request.

dinesh4official commented 4 years ago

@mdazharuddin1011999 thanks