#TLShadow
1 messages ยท Page 1 of 1 (latest)
Hi,
I'm not sure I'm understanding your question well.
Do you mean like an API that your JS script calls and verify if a card is valid or not ?
ok let me give a little more context .. we have a plattform and use the whitelabel checkout currently
we want to go into a more Stripe JS integration way, so that cardnumber,cvc will be asked inside our shop of our customer .. and his customer doesn't need to be redirected to the white label solution.
And i noticed taht stripe uses JS endpoints to validate the card before submitting preventing false requests .... to realize that with our plattform we would kinda need to have the possibility to validate the card aswell .. because the current structure requres our backend to be informed of orders
so direct JS sdk implementation is out of option
In fact, yes Stripe JS provide input validation as the customer types card informations: https://stripe.com/docs/js/element/input_validation
The validation is just a format validation (valid date input, valid card number using Luhn's algorithm) and not checking if the payment can be done or not using a card,
What do you mean by JS endpoints? Javascript is executed in the customer browser not an API
ok .. wait a second .. the input validation pre submitting is completly without ajax communiction ?
i thought it would senc card + cvc and date to stripe and validate it .. to recognize card type and if the number itself would be validate
but as i understand now this is only done locally by using luhn
Luhn and other validation/formating rules (for example: postal code https://stripe.com/docs/js/element/postal_code_formatting)
But it's in the local browser of the user, you can inspect the network while typing for example and you'll see no call is done while typing and validating
ahh ... okay so i overlooked that fact ... ok i guess this answers my question then ๐
Glade to hear that. Let me know if there's any follow-up Qs I can answer ๐
thanks alot ๐