Generate error codes from tokenized transactions

You are here

6 posts / 0 new
Last post
Generate error codes from tokenized transactions
We are using the token approach to sage payments. We'd like to test our application's UI when the credit card is declined. We've used all the test credit card as listed on here. How can we generate error codes using the sandbox?
Re: Generate error codes from tokenized transactions

Thanks for your post, we're happy to help. We have a document that we can provide with test cards and amounts that will trigger specific responses such as approvals and declines. I will be happy to email you this information. If any other integrators need this document please reach out to us at [email protected] and we will be happy to send it to you. I have included a few examples below, but the document includes much more. If you'd like to test an expired card you can just use a month and year prior to today's date. Otherwise all expiration dates beyond today should work. Also most test cards will return Approved for $7.00.

Test Card Number: 4111111111111111

Amount: $2.00

Expected Response: Declined


Test Card Number: 5499740000000057

Amount: $4.00

Expected Result: Declined

I tried your solution with
I tried your solution with Test Card Number 4111111111111111 and $2 amount. The response is still approved for some reason. Can I post the request on  here? Someone else on our team had the app set up so I'm using his keys.


  Below are the Test Cardnumbers and the amounts that will resturn an decline/error.

Card Type Cardnumber
Visa 4111111111111111
MasterCard 5499740000000057
Discover 6011000993026909
Amex 371449635392376


Amount Response Indicator Response Code AVS Response Code CVV/CVV2 Response Code Response Message
$2.00 E 000002 null N DECLINED
$4.00 E 000004 null S DECLINED
$5.00 E 000005 null U DECLINED
$16.00 X 999999 null P UNABLE TO PROCESS


I got it to work and get the
I got it to work and get the expected result. I'm looking for a way to return the reason why the card was declined to show it to the end-user.   One document lists codes like 000000, 900000, 650104. Another document lists 000002, 000004 depending on the amount. I'm confused about the Response/Declined Codes.Can you clarify when to use which? Thank you
I don't have an example that

I don't have an example that will return the 000000 - Internal Server Error. The 900000-900022 error codes are mainly caused by incorrect values or unsupported characters. The 650102-650104 errors are based on the Risk Controls enabled in the Virtual Terminal. If you have a Test Account log into your Virtual Terminal, go to Configuration, and select Risk Controls. You can enable AVS and/or CVV restrictions. The Testing Procedures doc will have amounts that return a specific AVS and CVV code that will trigger the 650... error. 

Log in or register to post comments