Tapaya
Getting StartedTesting / Sandbox

Testing / Sandbox

Learn how to validate your integration using the sandbox environment and testing tools.

Enable Sandbox Mode

To start testing your integration without processing real payments, you must initialize the SDK in demo mode. This ensures that all transactions are routed to the sandbox environment and no real money is moved.

// Initialize with demo = true
AcceptSDK.initialize(
    context = applicationContext,
    token = AcceptSDKDEMO_TOKEN, // or your sandbox merchant token
    demo = true
)

Simulate Transaction Outcomes

In the sandbox environment, the outcome of a transaction is determined by the decimal part of the transaction amount. Use these specific amounts to test how your application handles different scenarios.

Decimal AmountOutcomeDescription
.82 (e.g., 10.82)ApprovedSimulates a successful transaction.
.83 (e.g., 10.83)DeclinedSimulates a generic decline.
.84 (e.g., 10.84)RefundedSimulates a refund of transaction.
.85 (e.g., 10.85)FailedSimulates a gateway or network error.

Amount Format

Remember that the SDK typically accepts amounts in the smallest currency unit (integers). To test 10.05, you would pass 1005 as the amount.

Test with Tapaya Accept Testing Tool

Availability

Testing tool is right now available only for early adopters.

To test NFC payments without using physical cards, use the Tapaya Accept Testing Tool. This is an HCE (Host Card Emulation) Android app that simulates a contactless card.

  1. Install the Tool: Download and install the "Tapaya Accept Testing Tool" on a secondary Android device with NFC.
  2. Configure Card: Open the app and select a test card profile (e.g., Visa, Mastercard).
  3. Perform Transaction: Initiate a payment in your app and tap the testing device against the back of your terminal device.

On this page