Flexpay offers a sandbox environment to clients to test the new integration setup before going live. Once all testing has been completed and the integration is ready to go live, FlexPay's support team will switch the account from sandbox mode to live mode. You can access the sandbox environment in your FlexPay account at the top right of the page. Move the toggle in the direction of "sandbox" for sandbox mode as shown in the picture below.



The sandbox environment provides access as if you were in a live environment allowing clients to safely simulate different response codes between FlexPay and the clients CRM without actually sending transactions to your payment gateway and as such test transactions do not generate a response error code.


There are predefined inputs that are required to validate gateway response codes by using specified amounts, specific test cards and specific transaction types. These inputs are shown in the various tables below.

        

Test Cards

The test cards provided in the table below can be used to process transactions with a predefined output. Any other card numbers will generate a decline with 30016 as a response code.


Card
Number
Exp. Month
Exp. Year
CVV
Visa
4920201996449560
07
2021
879
MasterCard
5244209084665514
07
2021
010
Amex
341674949684898
07
2021
1000
Diners Club
30349475125576
06
2021
100
JCB
3530111333300000
06
2021
100
Discover
6011885753412897
06
2021
100


Response Codes

The table below shows the exact amounts (in pennies) that will trigger a specific predefined response. A charge with any other value than those listed, will return a successful/approved response; code (10000).


Amount (In Pennies)
Response
Description
2005
20000
You need to refer to the Card Issuer
2008
20003
Declined - do not honour
2012
20023
The card has been declined due to insufficient funds.
3016
30011
Invalid transaction
4018
40000
Risk Blocked Transaction refused due to risk model
5023
50000
Validation error

AVS

The table below outlines the data to be used to test Address Verification System (AVS) response codes. Each input item triggers a predefined output. Any other value in the address line 1 field will return AVS check 'S' for unsupported.


Address Line 1
AVS Check
Description
Street_A
A
Address matches, but zip code does not.
Street_E
E
AVS not supported for this industry.
Street_N
N
No part of the address matches.
Street_S
S
AVS not supported.
Street_X
X
Exact. Nine-digit zip code and address match.
Street_Y
Y
Yes. Five-digit zip code and address match.

CVV

The card verification value (CVV) can be tested by entering the inputs below. The predefined elements in the description column will be received. Any other CVV will return CVV check "M" match.


Card CVV
Response Code
CVV Check
Description
201
30049
U
(Unknown) - Issuer is not certified and/or has not provided Visa encryption keys.
202
40006
N
(No Match) – The CVD value provided does not match the CVD value associated with the card.
203
10000
M
(Match) – The CVD value provided matches the CVD value associated with the card.
204
30049
Q
(Unknown Response) – No results were received concerning the CVD value.
205
30049
P
(Not Processed) – The CVD value was not processed.
206
40003
S
(Not Present) – CVD should be on the card. However, the cardholder indicated it was not present.


Disabling Customer Recovery

The customer recovery can be disabled by setting the DisableCustomerRecovery field to True. This option is used on a new sale when you are charging the customer for the first time. The two cases are: producing an approved on billing cycle 1 then a declined on billing cycle 2, the second is, a declined with a disabled recovery that will generate a do not retry response code.


Amount (In Pennies)
Disable Customer Recovery
Response Code
Description
6020
True
10000
Approved
6020
False
20000
You need to refer to the Card Issuer
7028
True
30080
DO NOT RETRY - You need to refer to the Card Issuer

 

Advanced Void and Refund Testing

In the first scenario we can do a Charge approved transaction with the specified amount; If we do a Void on this recently approved Charge transaction, we will have a Decline response code. Now if we do a Refund for the same approved Charge transaction, it will be approved.


In the second scenario we can do a Charge approved transaction for the specified amount and then do a Void for this transaction, the transaction will be approved and we will have the Approved response code.


In the third scenario we can do a Charge approved transaction with the specified amount and then do a Refund for the same approved Charge transaction, the Refund transaction will be approved and we will have the Approved response code


The table below charts out exact amounts (in pennies) that will trigger a specific predefined response.


Scenario

Amount (In Pennies)

Transaction Type
Response Code
Description

1

9000
Charge
10000
Approved

Void
30013
The reversal request failed

Refund
10000
Approved

2

7514
Charge
10000
Approved

Void
10000
Approved

3

9001
Charge
10000
Approved

Refund
10000
Approved


Partial Refund

In the first scenario we can do a Charge approved transaction for the specified amount and then do a Refund for this transaction using ‘0’ as the refund amount, the refund transaction will be approved for the full amount and we will have the Approved response code.


In the second scenario we can do a Charge approved transaction with the specified amount; If we do a partial refund on this recently approved Charge transaction, we will have an Approved response code. Now if we do a Partial Refund for the remaining amount of the approved Charge transaction, it will be approved for the refund of remaining amount.


In the third scenario we can do a Charge approved transaction for the specified amount and then do a Refund for this transaction using an amount higher than the Charged amount, the refund transaction will be Declined and we will have the Declined response code along with the Decline message.


The table below charts out exact amounts (in pennies) that will trigger a specific predefined response.


Scenario


Amount (In Pennies) 

Transaction Type
Response Code
Description

1

9000
Charge
10000
Approved
0
Refund
1000
Approved and Full amount is refunded




2

7500
Charge
10000
Approved
4000
Refund
10000
Approved – Partial Refund
3500
Refund
10000
Approved – Partial Refund

3

5000
Charge
10000
Approved
5500
Refund
30015
Declined – The external gateway has reported that you have submitted an invalid amount with your request.