#jimmy - question

1 messages ยท Page 1 of 1 (latest)

dusty pewter
#

Hi ๐Ÿ‘‹
What's up?

plucky hill
#

Hi ๐Ÿค

I have a control panel where I give my customers a way to add a new card and assign it to their subscription. I using CardCvcElement, CardExpiryElement, CardNumberElement for this test, because I have my own UI.

So, using your test cards as "Insufficient Funds Decline" (4000000000009995)

I am creating the token with stripe.js and I realized that when creating the token it does not validate or return an error that the card does not have enough funds

#

This my handleSubmit

dusty pewter
#

Yeah the Tokens API is very old and does not support those functions

#

It merely tokenizes the data to avoid sending raw PANs in your request

plucky hill
#

Is there a way to add new cards using card elements with validation?

#

I have my own UI for this case use

dusty pewter
#

Not for insufficient funds

#

that is not something the issuing bank will share unless you attempt payment

#

That's how it works in the real world too

plucky hill
#

I undertand it

#

What solution could I do to add a new card with validation?

#

What do you recommend me?

#

Is there a way to add a payment intent but only to add the card without paying anything about it?

dusty pewter
#

A) You can validate using a Setup Intent but this will still not cover insufficient balances.

#

B) If you are going to charge a customer you can use a separate authorization and capture process to first validate they have the funds, then attempt to collect them

plucky hill
#

That would apply to cards like "Generic decline", "Lost card decline" and the others that have a test?

dusty pewter
#

I don't think so but you should try with those testing cards to validate. The issue is, the banks don't necessarily send us that information unless we attempt to collect funds.

#

The Setup Intent just pings the bank to say "this credit card exists, right?" But not, "can this card cover $1K purchases"

plucky hill
#

The Setup Intent, could you help me validate if the card has expired? or if your CVC is incorrect?

dusty pewter
#

Yeah, that would be covered

plucky hill
#

That's great!

#

Thanks a lot!