Make test purchase
To use sandbox environment, pass the "sandbox": true
parameter in the request body of the method to get a token:
- Create payment token for purchase — when you create an order on the server side.
- Create order with specified item — when you create an order on the client side.
To open the payment UI, use the following URL: https://sandbox-secure.xsolla.com/paystation4/?token=TOKEN
, where TOKEN
is the received token.
To switch to production environment:
- Sign the licensing agreement.
- Remove
"sandbox": true
parameter from the request body when obtaining a token. - Open the payment UI using the following link:
https://secure.xsolla.com/paystation4/?token=TOKEN
.
Open payment UI in sandbox mode
Make test payment
To test the payment process, you can use the sandbox mode. Sandbox mode is a stand-alone environment that supports all features of a live environment, except real and declined payments. You can access sandbox mode by sending "sandbox": true
when you create an order.
- Open the payment UI in sandbox mode.
- Choose the Bank card payment method.
- Enter the bank card details. In other fields (e.g., name or address), you can enter any data. You can also specify incorrect details (card number or expiration date) to test if an error is generated.
- Click Pay.
In addition to card details, you need to specify the ZIP code if at least one of the following conditions is true:
- The user’s country is the US or Canada.
- The Bank Identification Number (BIN) indicates that a card was issued in the US.
You can specify any valid ZIP code (e.g., 12345). This determines the sales tax rate and does not affect the progress of the test payment.
Sandbox bank card payments can be made in the following currencies: USD, EUR, RUB, GBP, AED, ALL, AMD, ARS, AUD, AZN, BGN, BRL, BYN, CAD, CHF, CLP, CNY, COP, CZK, DKK, DZD, EGP, GEL, HKD, HRK, HUF, IDR, ILS, INR, ISK, JPY, KES, KGS, KRW, KZT, MAD, MDL, MKD, MNT, MXN, MYR, NGN, PEN, PHP, PKR, PLN, RON, RSD, SAR, SEK, SGD, THB, TRY, TWD, UAH, UYU, UZS, VEF, VND, ZAR.
To see transactions made in sandbox mode:
- Open your Publisher Account.
- Go to Accounting > Transaction registry.
- Check the Show test transactions box.
Found a typo or other text error? Select the text and press Ctrl+Enter.