#wpg_test-expiredcard

1 messages · Page 1 of 1 (latest)

whole crowBOT
#

👋 Welcome to your new thread!

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1263890314142421234

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

kindred needle
#

Our flow is that we use setup checkout to allow users to add a payment method. We then list the payment methods, which we retrieve from the payment methods API. However, the only way to test what happens when card is expired is to create a new valid card that expires this current month, and then wait until the end of the month. This isn't very convenient for testing.

fickle briar
#

@kindred needle that's unfortunately not something we support

#

wpg_test-expiredcard

#

We (Stripe) don't really handle expired cards any different way. You can still charge it, many banks still allow payments to go through, so you don't need to do anything specific to test this

kindred needle
#

But then the payment will fail, right?

fickle briar
#

no

kindred needle
#

How can an expired card be charged? I have had cards expire and I get emails from companies saying to update my card because they couldn't charge it

#

I've never heard of this

fickle briar
#

¯_(ツ)_/¯ not sure what to tell you.

#

It does work, many banks know "oh that merchant charged that card before it was updated, it's fine".

#

And also we have "automatic card updates" where we work with banks to automatically update those cards.
As a developer all you need to do is handle declines and if they happen get the customer back on session

kindred needle
#

We currently use the invoice API and subscription API, and we detect failed payments by invoice.payment_failed. Does that sound right?

fickle briar
#

yes!

kindred needle
#

to handle 'declined' I mean

#

Thanks!