You can use these methods for card payment method integration.
The SDK provides a method to get the card network name of the provided card number.
- At least 6 digits of the card number are required to identify the network.
- Possible values returned by this method are,
visa
,mastercard
,maestro16
,amex
,rupay
,maestro
,diners
andunknown
. - If it is not able to identify the network it returns
unknown
.
razorpay.getCardNetwork(cardNumber);
The SDK provides a checksum-based method to determine if the entered card number is valid or not.
razorpay.isValidCardNumber(cardNumber);
The SDK provides a method to get the length of the card number for a specific card network.
razorpay.getCardNetworkLength(cardNetworkName);