xendit / xendit-node

Xendit REST API Client for Node.js - Card, Virtual Account, Invoice, Disbursement, Recurring Payments, Payout, EWallet, Balance, Retail Outlets, QR Codes, Direct Debit
https://developers.xendit.co/api-reference/
115 stars 63 forks source link

EWallet.createPayment() vs EWallet.createEWalletCharge() #80

Closed hanprat closed 3 years ago

hanprat commented 3 years ago

What is the difference between EWallet.createPayment() and EWallet.createEWalletCharge()?

I've try DANA with createPayment() and with createEWalletCharge() too. Both have different flow. Using createPayment(), I can test with the "real" flow (pages in DANA for topup). But, using createEWalletCharge() the url-redirection is just a simple page with button "Proceed to pay" and when it's clicked saying something like "test is done". Is it supposed to be different in testing?

With createPayment() I can set the callback url, but where to set the callback url when using createEWalletCharge()?

luminto17 commented 3 years ago

hi @hanprat , great questions

Our official recommendations:

Regarding DANA's Proceed to pay experience, yes it's intended to behave the way you are seeing right now. Proceed to pay is a test-mode feature to replicate your customer's behavior to pay using DANA

Glad you ask to clarify. Teaser: Our ewallet team is planning to drop support safely for EWallet.createPayment(). As soon as they have published the deprecation plan, we'll add the deprecation note here for discoverability

Let me know if this answer your questions or not :)

hanprat commented 3 years ago

thanks @luminto17 for the explanation.

I can see why the readme change from createPayment() to createEWalletCharge(). Was using createPayment() for several months, and last few days can't find the doc/reference.

hanprat commented 3 years ago

Hi, @luminto17 In testing-mode, does your system still hit the callback URL for ewallet charge?

I can test the success payload in dashboard setting of eWallet Paid. But, how to test the non-success payload?

luminto17 commented 3 years ago

hi @hanprat absolutely, you can test negative scenarios here using these input https://docs.xendit.co/ewallet/integrations/test-scenarios