Description
CreditCardValidations is a Ruby gem that checks whether a card number is well formed before you attempt verification. It validates the number against the known ranges of card BIN numbers and runs a Luhn check, so obviously invalid numbers are caught early. Eight major brands are detected out of the box: American Express, China UnionPay, Diners Club, Discover, JCB, Maestro, MasterCard and Visa. Regional and specialty networks, such as Cartes Bancaires, Dankort, Elo, Mada, Mir, RuPay and Verve, are available as opt-in plugins. The project explains that plugins add no startup cost and no chance of misdetection for apps that do not accept a brand. Legacy and withdrawn networks are listed separately with their status. You install the gem by adding it to your application's Gemfile. The source is on GitHub under the didww organization.…
Highlights
- Validates card numbers against BIN ranges and the Luhn check
- Eight major brands detected out of the box
- Opt-in plugins for regional and specialty networks
- Legacy and withdrawn networks listed with their status
- Ruby gem with source on GitHub
Ratings & Reviews
No ratings yet
Be the first to rate Credit Card Validations.
People also visit
Credit Card Validations FAQ
What is this gem for?
Checking that a credit card number is well formed before you try to verify it. It is a validator, not a payment processor.
Which card brands are detected by default?
American Express, China UnionPay, Diners Club, Discover, JCB, Maestro, MasterCard and Visa.
How do I add other networks?
Require the opt-in plugin for the network you need. The README says regional and specialty networks are detected only when their plugin is explicitly required.
How do I install it?
Add the gem to your application's Gemfile, as the README describes.
What are the best Credit Card Validations alternatives?
Popular alternatives to Credit Card Validations include Nope Validator, Email Spell Checker and myCart. See all Credit Card Validations alternatives






