Open judgej opened 7 years ago
Looking again at the docs, it seems that the card type is supplied in the API when a card identifier is created. This is an example response:
{
"cardIdentifier" : "C6F92981-8C2D-457A-AA1E-16EBCD6D3AC6",
"expiry" : "2015-06-16T10:46:23.693+01:00",
"cardType" : "Visa"
}
It is just that the default JS onTokenise
handler does not put the card type into the form to be submitted. Maybe just a custom handler is what is needed?
I think this is a non-issue now?
The front end card tokenisation does not supply the card type. If the application is to add surcharges to specific cards, then it needs to know the card type before sending the payment request.
The card type will be supported in this gateway card tokenisation response soon, but until then, something like http://jquerycreditcardvalidator.com/ can provide a workaround by determining the card type on the front end and including it in the submitted form. This is unlikely to work for the iframe CC form, but would work for a custom CC form.
This ticket is just somewhere to log any examples of how this can be done.