Skip to main content

Testing

The Mock Acquirer is a test environment that lets you test different payment flows and transaction results without processing real payments.

The test cards below can be used to simulate different scenarios for:

  • One-off payments
  • Refunds
  • Customer-Initiated Transactions (CIT)
  • Merchant-Initiated Transactions (MIT)
  • 3D Secure
  • Asynchronous payments
  • Authorization, capture, and settlement
  • Provider and technical errors
  • Timeouts
  • Subscription Module transactions

How test cards work​

Each test card number is linked to a set of actions. Each action defines the result the Mock Acquirer returns for one type of operation:

OperationWhen it applies
PaymentOne-off payments and the initial Customer-Initiated Transaction (CIT).
RefundRefunds of a payment made with the card.
RecurrenceRecurring Merchant-Initiated Transactions (MIT).
UnscheduledUnscheduled Merchant-Initiated Transactions (MIT).
3DS3D Secure authentication.

Use the following values for the rest of the card details:

FieldValue
Expiry dateAny future date.
CVCAny 3 or 4-digit value with a valid format.
info

Card numbers not included in the list return 0303 - Invalid credit card.

Card numbers included in the list but used with an operation that is not defined for that card return Approved. In the tables below, these operations are shown as —.

Test cards​

Select the scenario you want to test. Each table shows the result returned for each operation:

  • ✅ Success — the operation is approved or refunded.
  • ❌ Failed — the operation fails with the error code shown.
  • ⏳ Pending — the operation stays in process or pending.
  • ⏱️ Timeout — a timeout is forced before the result shown.
  • — Not defined — the operation is not defined for this card and returns Approved.

Cards that approve the payment and the refund. Use them to test the happy path of your integration.

Card numberBrandPaymentRefundRecurrenceUnscheduled3DS
4000000000000002VISA✅ Approved✅ Refunded✅ Approved✅ Approved—
4438341577554340VISA (prepaid)✅ Approved✅ Refunded✅ Approved✅ Approved—
378282000000008AMEX✅ Approved✅ Refunded———
378285000000019AMEX✅ Approved✅ Refunded✅ Approved——

The card 4438341577554340 returns Prepaid in CardType (BinInfo).

The following example shows a payment form filled in with the test card 4000000000000002:

Payment form filled in with a test card

Subscription module testing​

The Subscription Module has its own test logic. Test it with the dedicated subscription test card and use the CardHolder value to control how the recurring transactions behave.

FieldValue
Card number4000056655665556
CardHolderA function that defines the result of the recurring transactions. See Functions.

How it works​

  1. The initial transaction always returns Approved. It starts the subscription test process.
  2. Each recurring transaction generated after the initial transaction is evaluated according to the function in the CardHolder.
  3. The function is only applied when the CardHolder specifies an error.
info
  • Write all CardHolder functions in uppercase letters.
  • Specify the error with the format Exxxx, where xxxx is the four-digit Revup error code. For example: E0900.

Functions​

FunctionFormatExampleRecurring transactions result
AlternatedALT ExxxxALT E0900Approved and failed alternately, starting with approved.
CounterCxx EyyyyC03 E0200xx approved transactions, then failed with the error.
Special step<sequence> ExxxxSFSSFF E0900The exact sequence of approved (S) and failed (F) transactions.

Select a function to see how it works:

The Alternated function uses a counter in the initial transaction. When the initial transaction is generated, the counter is set to 0:

  • Each even counter value returns ✅ Approved.
  • Each odd counter value returns ❌ Failed with the error specified in the CardHolder.

The first recurring transaction is therefore always approved.

Format: ALT Exxxx

Example: ALT E0900

Recurring transaction1234…
Result✅ ❌ 0900✅ ❌ 0900…

The following example shows a payment form filled in with the Subscription Module card and the ALT E0900 function in the cardholder name:

Payment form filled in with the Subscription Module card and a cardholder function

Test codes​

The Mock Acquirer uses the following codes internally to define the result of each action:

CategoryCodeDescription
Success0001Approved
Success0002Refunded
Success0010Authorized
Success0011Captured
Success0012Settled
Pending0003In Process
Pending0004TDS (3 DS)
Subscription0020Subscription
Authentication0103Authentication Failed or Incomplete
Authentication0104Authentication Not Available
Authentication0105Authentication Required
Authentication0121Authentication Failed - 3D Secure
Declined0102Authorization Failed
Declined0109Issuer Unavailable
Declined0200Do Not Honor
Declined0205Restricted Card
Invalid data0152Missing or Invalid Data - Recurring Model
Invalid data0303Invalid Credit Card
Invalid data0304Unsupported Card Brand
Invalid data0312Missing or Invalid Data
Invalid data0900Bad Input
Refund error0170Refund Error
Refund error0171Refund Rejected - Payment Not Yet Captured, Try Again Later
Refund error0172Refund Rejected - Payment Already Charged Back
Technical error0108Transaction not found
Technical error0800Provider's Connection Failed
Technical error0801Provider's Technical Error
Technical error0901Internal Server Error
Async1001Approved Async
Async1002Refunded Async
Async1170Refund error Async
Async1171Refund Rejected - Payment Not Yet Captured, Try Again Later Async
Async1200Do Not Honor Async
Timeout2000Forced Timeout with Success
Timeout2001Forced Timeout with Failed - Authorization Failed
Other9999Custom Failed. (Dynamic from database)
Other0000Unknown

Summary​

The Mock Acquirer allows you to test payment behavior without using real cards or processing real transactions.

For most payment scenarios, select a card from the test cards tables according to the scenario you want to test.

For subscriptions, use the dedicated Subscription Module card:

4000056655665556

and configure the desired recurring behavior through the CardHolder using one of the supported functions:

  • ALT Exxxx
  • Cxx Eyyyy
  • <sequence> Exxxx