To create payment with eWallet in Live Mode, first you must be aware that eWallet has 2 type of flow (for further reference can go to this docs):
1. No Redirection Payment Flow/ Push Notification Flow:
- OVO
- JeniusPay
2. Redirection Payment Flow:
- DANA
- ShopeePay (ID & PH)
- LinkAja
- AstraPay
- GCash
- Paymaya
- GrabPay
Here are the steps on how to create eWallet charge in live mode:
1. Create secret API Key on your dashboard in live mode
Reference can be found in this doc.
2. Set your callback URL in Dashboard - Settings - Callbacks in eWallet payment status and make sure upon "test and save" it returns 2XX
3. Create eWallet Charge using endpoint:
POST https://api.xendit.co/ewallets/charges
4. Input you secret API key in Authorization
5. In Body Request you can input the parameters which are required or optional based on each eWallet partners (this example is for DANA):
{
"reference_id": "livetesting",
"currency": "IDR",
"amount": 100,
"checkout_method": "ONE_TIME_PAYMENT",
"channel_code": "ID_DANA",
"channel_properties": {
"success_redirect_url": "https://yourwebsiteurl/",
"failure_redirect_url": "https://yourwebsiteurl/"
},
"metadata": {
"branch_area": "PLUIT",
"branch_city": "JAKARTA"
}
}
{
"id": "ewc_8a20cc88-4407-47e1-9d4c-94720d118bc0",
"business_id": "603f1c4172bbe840979fd408",
"reference_id": "livetesting",
"status": "PENDING",
"currency": "IDR",
"charge_amount": 100,
"capture_amount": 100,
"payer_charged_currency": null,
"payer_charged_amount": null,
"refunded_amount": null,
"checkout_method": "ONE_TIME_PAYMENT",
"channel_code": "ID_DANA",
"channel_properties": {
"success_redirect_url": "https://docs.xendit.co/ewallet/integrations/test-guideline",
"failure_redirect_url": "https://docs.xendit.co/ewallet/integrations/test-guideline"
},
"actions": {
"desktop_web_checkout_url": "https://m.dana.id/m/portal/cashier/checkout?bizNo=20221207111212800110166925072150424×tamp=1670399887714&mid=216620000035833566172&did=216650000363067994173&sid=216660000362985537171&sign=nG82KephN2%2BnwAfr5itNljExC%2B38VqBO%2F55bJTKwGIaXIJsV6BiU3rvLPVLj9vpOYKcuB69fDOkoBURyEOOuzgS8a%2BaTNAtO2GLnlCe70ZDU3m04yedk3n0Pq8%2BHfFMgwLFeuU9HHqaWBcrfPJULqCivuTPZ%2BkK2oqBlNH9l0PeYboSWJedf1IfrHPuctWxCO4QlgGtfMH7RK6gNYYAxBRFq2Pf1XabLs%2F1W70DWeUBY%2FrrbYNyPqKi7vrSWmo%2BQI40C2fEJgL8PMkcNEM3wMM0SRYLuX1Ra7Fq%2FsfV4ndJo0uCzuTQk%2F%2BTBSiq1DM3Fh0dpkEemZMykhOeVrIuTPQ%3D%3D&forceToH5=false",
"mobile_web_checkout_url": "https://m.dana.id/m/portal/cashier/checkout?bizNo=20221207111212800110166925072150424×tamp=1670399887714&mid=216620000035833566172&did=216650000363067994173&sid=216660000362985537171&sign=nG82KephN2%2BnwAfr5itNljExC%2B38VqBO%2F55bJTKwGIaXIJsV6BiU3rvLPVLj9vpOYKcuB69fDOkoBURyEOOuzgS8a%2BaTNAtO2GLnlCe70ZDU3m04yedk3n0Pq8%2BHfFMgwLFeuU9HHqaWBcrfPJULqCivuTPZ%2BkK2oqBlNH9l0PeYboSWJedf1IfrHPuctWxCO4QlgGtfMH7RK6gNYYAxBRFq2Pf1XabLs%2F1W70DWeUBY%2FrrbYNyPqKi7vrSWmo%2BQI40C2fEJgL8PMkcNEM3wMM0SRYLuX1Ra7Fq%2FsfV4ndJo0uCzuTQk%2F%2BTBSiq1DM3Fh0dpkEemZMykhOeVrIuTPQ%3D%3D&forceToH5=false",
"mobile_deeplink_checkout_url": null,
"qr_checkout_string": null
},
"is_redirect_required": true,
"callback_url": "https://ewalletvoid.free.beeceptor.com",
"created": "2022-12-07T07:58:07.446368Z",
"updated": "2022-12-07T07:58:07.446368Z",
"void_status": null,
"voided_at": null,
"capture_now": true,
"customer_id": null,
"customer": null,
"payment_method_id": null,
"failure_code": null,
"basket": null,
"metadata": {
"branch_area": "PLUIT",
"branch_city": "JAKARTA"
},
"shipping_information": null
}
- For Redirection Payment Flow you will receive "desktop_web_checkout_url" and/or "mobile_web_checkout_url" under the "actions" section while for