#tony_cat
1 messages · Page 1 of 1 (latest)
add card
You mean like saving it for future payments?
what if user add a wrong card, but user did know it.
yes
but just after pay success
Got it! Yep, you can save card details for future payments during a payment: https://stripe.com/docs/payments/save-during-payment
Seems not resolve my issue.I can add card. but I don't want add card when user tap "Add" button. I want user add the card after pay success.
Are you using Customer objects? I guess you would do this with webhooks. Listen for the payment_intent.succeeded event and then attach the Payment Method to the Customer
Yep, the Payment Method ID will be returned in the payment_intent.succeeded event: https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Generally we don't recommend attaching that way though as it can be potential auth side effects with future payments
Got it.