#himana.dev

1 messages · Page 1 of 1 (latest)

noble escarpBOT
#

Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

wooden crown
#

You can use one of the declines card

dusk prawn
#

https://stripe.com/docs/testing

test with "4000000000000002" but it not trigger

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 and redirects.

#

should u give me some example

wooden crown
#

Um that should give you the decline error

#

What do you see on the log?

dusk prawn
#

self.paymentSheet.present(from: self) { [weak self] result in
switch result {
case .completed:

        case .canceled:

        case .failed(let error):
        }

}

i want to know when "failed" in code trigger

#

currently it can trigger "completed" , "canceled". But how about "failed" , when where?

wooden crown
#

Ah I see, it could be if the PaymentSheet itself can't open due to some more generic errors, ie. regulation errors or accounts error

#

I can't think of an effective way to trigger it, maybe if you reuse an already confirmed PaymentIntent? But in that case let's make sure you will give your customer a path forward in your UI