#coryschires
1 messages ยท Page 1 of 1 (latest)
๐ Happy to help
As the error mentions, this happens when a PaymentMethod is used before it is attached to a customer. How are these payment methods being created at the moment? I can help look in to how to attach them before or during the first payment
Here's a little more context...
Our customers often pay invoices via credit card. But they don't want Stripe to automatically save their card on their customer object (because they work for big institutions and do not have authorization to save the card info on an external service).
Last I checked, when a customer pays an invoice via credit card, Stripe automatically saves the card to their customer object. To avoid this behavior, we have some webhook code which automatically detaches the card after their payment has been completed.
I suspect our webhook code may be at play here, somehow messing things up.
But, one more detail, this webhook code has been in use since May 2022, and this has never been an issue. This problem on recently started happening.
One more thought... The timing that this problem emerged makes me wonder if it could somehow be related to https://stripe.com/payments/link? (which is currently enabled but I could disable it). I don't really have any evidence for this theory. Just pointing it out in case it rings a bell for you.
Gotcha, do you have the ID of a payment that this recently happened on? I can check in to it to see what happened with the payment method that got that error
(pi_1234)
Looking...
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
If you look thru the activity history, you can see "payment_intent.payment_failed" events
Where the relevant error is present
Looking in to that payment. Do you have a more recent example? Not required but it may be easier for me to find relevant logs
Sure. Looking...
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
And the relevant event: https://dashboard.stripe.com/events/evt_2NrrkEFH8YjjVMbF1DSQ1xgw
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
Thank you, checking in to that as well
And here's one more example:
Invoice: https://dashboard.stripe.com/invoices/in_0NqG9jFH8YjjVMbFdBfKUKyB
Event: https://dashboard.stripe.com/events/evt_2NqH6MFH8YjjVMbF0CEnBUyF
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
I think that's all the examples I have in my internal notes
Sounds good, I think that should be plenty to look this up. I'm not familiar with the pattern that I am seeing here, so I've reached out to a colleague and will get back to you with what we find
So it looks like that source was detached between when it was created and when the user completed the challenge on their payment https://dashboard.stripe.com/logs/req_92eEcdo7mMxgQp
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.