Simulating Test Payments
Introduction
When your account is created in Durianpay, you will immediately gain access to the sandbox feature. This feature will allow you to play around with Durianpay's products without having real consequences in the production environment. The sandbox environment is accessible with different API Keys than the LIVE ones, and there will be a different section in Durianpay's Dashboard for sandbox data.
Getting your Sandbox API Keys
Your sandbox API Keys will be shown in your Durianpay dashboard's API Keys page alongside your LIVE API Keys.
Simulating a payment
To simulate a payment status in sandbox mode, the steps will be as follows:
Step 1: Create a payment in sandbox mode
Creating a sandbox payment can be done by both API and Dashboard, the same with LIVE mode. Specifically for payment creation with API, the difference between the ones in LIVE will only be the API Keys. Where you will have to send a proper request body (i.e., the same with LIVE mode) and to the same API endpoints.
Step 2: Simulating the Payment Status
Payment status can be simulated by using the "Simulator" feature in Durianpay dashboard. To access this feature, you must:
- Login to your Durianpay Dashboard account
- Change your Durianpay Dashboard's mode to
Sandbox
- Access the Simulator page in Durianpay dashboard
On this page, there will be a function to manually mark a sandbox transaction with a specific status, as shown below:
Afterwards, if you have configured your payment webhook in the sandbox environment, corresponding webhook will be sent towards the URL (i.e., your server) that you have specified.
Callback configuration in Sandbox environment is exclusive with the one in LIVE environment. When you are going LIVE, please ensure the webhook is also configured in LIVE environment.
Updated about 1 month ago