#cgy

1 messages · Page 1 of 1 (latest)

fallen pythonBOT
vast dawn
#

I guess by 'offline' you mean off_session: true?

daring mango
#

yes

vast dawn
#

Then you'd just use a card that is going to fail, from: https://stripe.com/docs/testing

Use test cards to validate your Stripe integration without moving real money. Test a variety of international scenarios, including successful and declined payments, card errors, disputes, and bank authentication. You can also test non-card payment methods.

daring mango
#

Great that is what I want. Thank you very much

vast dawn
#

Easiest would be one that requires auth: 4000002760003184

#

Because it's an off-session payment, it'll just decline as the customer isn't available to authenticate

daring mango
#

OK, I should make sure failed one be dispose properly.

vast dawn
#

What do you mean?

daring mango
#

Just ignore the sentence. I am not very good in English.

vast dawn
#

np!

#

Hope your issue is solved

daring mango
#

🥰

#

Hi, still there?

#

I am not mean this decline. I mean I should collect the card info, and charge off_seesion.

#

Is there be a card which saved correctly, but when charged failed

#

Because a card may be lack of money or somthing else.

vast dawn
#

Sorry, I don't understand the issue

daring mango
#

Let me make it more understandable. If a card was saved, but when I charge the card may be lack of money or something else right? That's the situation "payment_intent.payment_failed"

#

I want a card meet this requirement.

#

Or how can I make a card charge failed to test my code

vast dawn
#

There's cards here to simulate declines for insufficient funds, etc: https://stripe.com/docs/testing#declined-payments

Use test cards to validate your Stripe integration without moving real money. Test a variety of international scenarios, including successful and declined payments, card errors, disputes, and bank authentication. You can also test non-card payment methods.

fallen pythonBOT
daring mango
#

Sorry, I still not find the one.😭

spark hull
daring mango
#

Hi, I tried.

#

But I should save it first, because I use SetUpIntent

#

I mean SetupIntent work well, and then PaymentIntent failed

spark hull
#

then use this card instead :

daring mango
#

ok

#

This card when I use api "PaymentIntent.create" it failed. When will it be webhook "payment_intent.payment_failed"

spark hull