Test real payments in production using Rainforest virtual credit cards

Rainforest Virtual Credit Cards

Rainforest QA lets you test real payment functionalities in production on demand. Rainforest’s virtual credit cards (VCC) are real credit cards that represent real credits and generate real transactions. They can be used any place where major credit cards are accepted.

With virtual credit cards, you can test payments without needing to use dummy credit card number generators, gift cards, or corporate credit cards. Credit card generators don’t work in production, while gift cards are blocked by some companies. Gift cards, including reloadable cards by Visa, can be costly and don’t represent real credit cards – they can usually be detected as gift cards by the payment processor, and some companies will opt to block gift cards from being used.

How VCC Works

Virtual credit cards are single use and have a maximum transaction limit, which is typically between $1.00-$50.00. This amount can be toggled under Settings > Step Variables.

You can incorporate virtual credit cards into your tests using the corresponding built-in step variable. The following fields are available: card_number , expiry , cvc , zip and address. Rainforest provides all values to each tester once the test is run. The zip code is 94111 and the card type is Mastercard.

Virtual Credit Card expiry date options

By default, the {{virtual_card.expiry}} variable will automatically return the date in the format YYYY-MM. You can also manually input an argument to the variable to change the format of the date output by using Ruby's implementation of date formats.

Using May 2022 as an example, here are some ways you can make the variable output match your platform:

  • {{virtual_card.expiry}} => 2022-05
  • {{virtual_card.expiry(%m-%y)}} => 05-22
  • {{virtual_card.expiry(%Y/%-m)}} => 2022/5


After the test is completed, Rainforest immediately destroys the virtual credit card so that it can no longer be used. Each card is also single-use and cannot be reused after it has been used for testing, even if the tested transaction amount is below the limit.

 Please Note: for security reasons, virtual credit card numbers do not show up in preview mode.

Deposits and Refunds

Rainforest QA holds a fully refundable deposit to serve as collateral for the virtual credit card. Rainforest can only issue virtual credit cards while the sum of the total virtual credit card limit outstanding does not exceed the deposit amount, net of any refunded transactions.

We track all transactions charged by the merchant ID’s associated with your account. As you receive payments from Rainforest QA via this feature, please issue refunds. Any unreimbursed transactions will count against your balance. Refunds can generally take 2-3 days to reflect on the account.

How Much to Deposit

Rainforest typically recommends $5000 as a fully refundable deposit to make sure there’s ample room for testing and scaling.

The following formula can be used to calculate how much of a deposit is required, assuming refunds are issued by the client within 24 hours:

Max Card Amount * No. of Tests Run with VCC in 3-day period * No. of Platforms * 2

For example, for a customer with a card limit of $50 who is running a daily smoke of 2 VCC tests on 2 Chrome and Firefox, we would recommend $50 * 2 tests * 3 days * 2 platforms * 2 = $1200. This is assuming all transactions are refunded right away.

How to enable VCC for my account

If you would like to learn more about VCC or are interested in enabling the feature for your account please contact your CSM.

Did this answer your question?