Testing Payment on Sandbox
Sandbox Environment can be used to create "testing" transactions (usually performed from your development/testing environment). All transaction made within this environment mode is not "real", and does not require "real payment/fund". This environment is created automatically when you are signing up, and free to use.
In the Sandbox environment, Midtrans uses web-based simulator to simulate a response from payment provider or bank's system. This helps to test different scenarios that can happen on production, without actually doing real payments.
This is the list of payment credentials that you can use on Midtrans Sandbox environment. Please note that, it will not work on Production environment.
Card Payments
The table given below lists the details to be entered for simulating credit card transactions. All cards listed below already support 8 digit BINS.
| Input | Value |
|---|---|
| Expiry Month | 01 (or any month) |
| Expiry Year | 2025 (or any future year) |
| CVV | 123 |
| OTP/3DS | 112233 |
| Card Number | Refer to table given below. |
General
VISA | Description |
|---|---|
Full Authentication |
|
Attempted Authentication |
|
MASTERCARD | Description |
|---|---|
Full Authentication |
|
Attempted Authentication |
|
JCB | Description |
|---|---|
Full Authentication |
|
Attempted Authentication |
|
American Express (AMEX) | Description |
|---|---|
Full Authentication |
|
Attempted Authentication |
|
China Union Pay (CUP) | Description |
|---|---|
Full Authentication |
|
Attempted Authentication |
|
FDS refers to our Fraud Detection System. "Denied by FDS" means to simulate a transaction that is being denied because it is suspected as fraudulent.
NoteNot all acquiring banks support JCB, Amex, or CUP cards. Please contact us for more information or assistance with activation of JCB, Amex, or CUP acceptance.
Bank-Specific
This is useful for Installment/Promo scenario which require bank specific card.
Accepted 3D Secure Card
Bank | Card Number |
|
|---|---|---|
|
|
|
Attempted Authentication | 4617 0017 4194 2101* | 5573 3819 9982 5417 |
|
| |
Attempted Authentication | 4097 6611 1111 1139* | |
| *Card not available for online installment/promo | ||
|
|
|
Attempted Authentication | 4599 2039 9705 2898 | 5481 1671 2103 2563 |
|
|
|
Attempted Authentication | 4105 0525 4151 2148 | 5264 2249 7176 1016 |
BNI Private Label | 1946 4159 8148 7684* | |
| *Card only acceptable via BNI Acquiring. | ||
|
|
|
Attempted Authentication | 4773 7738 1098 1190 | 5229 9073 6430 3610 |
|
|
|
Attempted Authentication | 4365 0278 6723 2690 | 5520 0254 8646 8439 |
|
|
|
Attempted Authentication | 4201 9100 0000 0017 | 5221 0300 0000 0017 |
|
|
|
Attempted Authentication | 4055 7713 3514 4012 | 5520 0867 7490 8452 |
Denied Card
Bank | Card Number |
|
|---|---|---|
Mandiri | 4617 0085 6083 1760 | 5573 3840 4322 4447 |
Mandiri Debit | 4097 6676 7217 8631 | |
CIMB | 4599 2060 0973 3090 | 5481 1691 9178 2739 |
BNI | 4105 0541 4854 1363 | 5264 2235 3013 1711 |
BNI Private Label | 1946 4102 7193 1269 | |
BCA | 4773 7752 0201 1809 | 5229 9034 0542 3830 |
BRI | 4365 0286 6251 2583 | 5520 0219 0920 3008 |
MEGA | 4201 9100 0000 0025 | 5221 0300 0000 0025 |
Maybank | 4055 7796 2846 0474 | 5520 0883 1465 3770 |
Denied Card By Response Code
| Card Number | Response Code | Note |
|---|---|---|
| 4472 4298 6999 6670 | 51 | Any amount will return RC:51. |
| 4806 0000 0000 0081 | 51 | The amount needs to be greater than Rp 30,000 |
Offline Card
It is used for testing a specific scenario where the card is not eligible for online transactions, which result in Deny transaction status.
| Brand | Card Number |
|---|---|
| VISA | 4705 8595 1098 4866 |
| MASTERCARD | 5597 5189 2656 1951 |
Note
- General card number is used for general feature testing of card payment.
- Bank specific card number is useful for testing advanced card features (on-us/off-us installments, whitelist BIN, promo, and so on) that require card from specific bank.
3D Secure Version Specific
3DS 2 Behavior Change NoticeTo reflect the changes that has been applied to our Production Environment, on 31st January 2023 similar changes is applied to Sandbox Environment. The changes are summarized as follows:
- Most/all acquirer bank MIDs within merchants’ sandbox accounts is upgraded to allow accepting 3DS 2. The previously MIGS acquirer MID's
channelwill be replaced with MPGS. Which will change the transaction's value ofchannel_response_messageandchannel_response_code. As explained in this notice.- All sandbox testing cards (that were previously 3DS 1) are upgraded to 3DS 2. Including cards listed under General and Bank Specific tabs.
- These changes are supposed to be seamless, not cause breaking, and not require changes of implementation from the merchant side (except IF merchant is still using a very old pre-2019 card integration flow, then card transaction will be treated as 3DS 1).
- Background context: 3DS 1 has been phased-out & upgraded to 3DS 2 in Production Environment & industry wide. Hence the same are applied to Sandbox.
3D Secure 2
Specific cards for testing 3DS 2 card payment scenario.
VISA | Description |
|---|---|
Card 3DS 2 Enrolled. |
|
Card 3DS 2 Enrolled. |
|
3DS authentication is either failed or could not be attempted; possible reasons being both card and Issuing Bank are not secured by 3DS(technical errors or improper configuration). |
|
MASTERCARD | Description |
|---|---|
Card 3DS 2 Enrolled. |
|
Card 3DS 2 Enrolled. |
|
3DS authentication is either failed or could not be attempted; possible reasons being both card and Issuing Bank are not secured by 3DS(technical errors or improper configuration). |
|
AMEX | Description |
|---|---|
Card 3DS 2 Enrolled. |
|
Card 3DS 2 Enrolled. |
|
3DS authentication is either failed or could not be attempted; possible reasons being both card and Issuing Bank are not secured by 3DS(technical errors or improper configuration). |
|
3D Secure 1
Specific cards for testing outdated 3DS 1 card payment scenario, which will be rejected due to no longer supported.
| Brand | Card Number |
|---|---|
| Visa | 4723249479082225 |
| MasterCard | 5555666677771111 |
| JCB | 3528927894502153 |
| Amex | 3419184532253540 |
E-Wallet
QRIS Simulator Intermittent IssueCurrently there's an issue with QRIS simulator affecting some of our older merchant accounts. If QRIS simulator doesn't work for you, please reach out to [email protected].
Payment Methods | Description |
|---|---|
GoPay | On mobile platform you are automatically redirected to GoPay Simulator. Other Notes:
|
ShopeePay | On mobile platform you are automatically redirected to ShopeePay Simulator. On desktop, QR Code image is displayed. To perform a test transaction, input the QR Code image URL in QRIS Simulator. In case you need to manually input Deeplink URL, use Deeplink Simulator |
QRIS | To perform a test transaction, copy the QR Code image URL and input it into QRIS Simulator Other Notes:
|
|
|
|
|
NoteOn Sandbox, Midtrans uses web-based payment simulator. So, payment that requires app deeplink like GoPay, will use web simulator instead of real app deeplink. To test real app deeplink use cases, please use Midtrans Production Environment.
Bank Transfer
| Payment Methods | Description |
|---|---|
| Permata Virtual Account | Midtrans will generate a dummy Permata Virtual Account Number. To perform a test transaction, use the Permata Virtual Account Simulator - Open API and choose Permata as the bank. |
| BCA Virtual Account | Midtrans will generate a dummy BCA Virtual Account Number. To perform a test transaction, use the BCA Virtual Account Simulator. |
| Mandiri Bill Payment | Midtrans will generate a Payment Code to complete payment via Mandiri e-channel (Internet Banking, SMS Banking, Mandiri ATM). To perform a test transaction, use the Mandiri Bill Payment Simulator - Open API and choose Mandiri as the bank, input company code as bill code and Mandiri Bill number as bill key. |
| BNI Virtual Account | Midtrans will generate a dummy BNI Virtual Account Number. To perform a test transaction, use the BNI Virtual Account Simulator. |
| BRI Virtual Account | Midtrans will generate a dummy BRI Virtual Account Number. To perform a test transaction, use the BRI Virtual Account Simulator - Open API and choose BRI as the bank. |
| CIMB Virtual Account | Midtrans will generate a dummy CIMB Virtual Account Number. To perform a test transaction, use the CIMB Virtual Account Simulator - Open API and choose CIMB as the bank. |
Convenience Store
| Payment Methods | Description |
|---|---|
| Indomaret | Midtrans will generate a dummy Indomaret Payment Code. To perform a test transaction, use the Indomaret Simulator. |
| Alfamart | Midtrans will generate a dummy Alfamart Payment Code. To perform a test transaction, use the Alfamart Simulator. |
| Kioson | Midtrans will generate a dummy Kioson Payment Code. To perform a test transaction, use the Kioson Simulator. |
Google Pay
To test, join Google Pay™ test environment here. Register as member of Google Pay™ API Test Cards using the email that you will use to do the test checkout. Registration will be auto approved.
After joining the test environment, test cards will automatically appear in your Google Pay™ wallet
These test cards will ONLY appear when you're signed in with your registered Google Account in test environment
Test cards will NOT appear in production environment.
| Success Cards | Decline Cards |
|---|---|
| Visa : 4811 1111 1111 1114 | Visa: 4811 1111 1111 1114 |
| Mastercard: 5211 1111 1111 1117 | Mastercard: 5111 1111 1111 1118 |
Cardless Credit
| Payment Methods | Description |
|---|---|
| Akulaku | Midtrans will automatically redirect to Akulaku simulator page. Test credentials will be displayed. |
| Kredivo | Midtrans will automatically redirect to Kredivo simulator page. Test credentials will be displayed. |
Note & Limitation
Sandbox Env Should Not be Paid with Real Payment
NoteDo not attempt to pay with a real-world payment-provider/bank to a transaction created in the Sandbox environment. Sandbox transactions cannot be paid with real payment, and should only be paid with the Sandbox Payment Simulator/Credentials explained in this page.
Midtrans will not be responsible and may not be able to help you recover any real-world payment funds if you do such an action.
Explanation: A payment reference generated on Midtrans Sandbox environment (VA number, QR image, etc.), may possibly be the same reference that is also active on the payment provider’s real environment. If you make a real payment to it, the funds will be routed to the real payment provider’s environment instead, which often the funds will not reach Midtrans. So please keep the environmental difference in mind.
QRIS Specific
For QRIS payment method, usually the sandbox reference will refer to the same Merchant ID you have in your Midtrans Production environment, real payment made there can possibly be routed to your Midtrans Production account. You can try to login to your Midtrans Production account, and may find payment with Order ID formatted as: QRIS-{generated_id}, which you can also try to refund.
Updated 6 days ago