#dane-paymentmethod-error
1 messages · Page 1 of 1 (latest)
dane-paymentmethod-error
@regal wind that errorcan't be specific to Apple Pay. Apple Pay works the exact same way. So it's about your integration reusing a pm_123 that was never attached to a Customer
Understood, but it looks like we are attaching the customer info in the request. Here's the full request:
{ "description": "Renewed parking reservation - SPOT 33 - 2/7/2024 @ 12:00 pm to 2/8/2024 @ 12:00 pm", "metadata": { "renewal_id": "REDACTED" }, "currency": "usd", "off_session": "true", "customer": "REDACTED", "payment_method": "REDACTED", "confirm": "true", "amount": "400" }
Let's take a step back: what is the exact request id that is failing? The req_123?
req_7gQjwQWOjPwZ62
Okay so that request fails. Where does that pm_123 come from? Is it currently attached to that Customer?
It's not, and that's the issue, I'm guessing. When I look up cus_PVy847PHgsldWn in Stripe I don't see a payment method on the account.
yeah, for a PaymentMethod to be reusable it first has to be attached to a Customer as part of the first payment. You likely missed this but it's not clear as you didn't share much more context.
Looking at your logs you seem to use the Charges API a lot in production but in Test mode you're doing PaymentIntent with React Native and rushing through errors.
I'm happy to help but would need a clear/canonical question
We just published a change in our stripe service code. Originally, for platform payments, we had
paymentIntentRequest.off_session = false;
But we just changed it to:
paymentIntentRequest.setup_future_usage = 'off_session';
In local testing that appears to have done the trick.
To address your last point--we aren't using Apple Pay in production and don't have automated tests running in dev/staging such that you'd see a lot of activity in Test mode.
What do you mean by "rushing through errors"?
When I looked at your logs, I saw multiple separate sequential errors you were hitting and resolving as you went like https://dashboard.stripe.com/test/logs/req_x8S8g209wYeK1U
I think what you're seeing is an initial reservation followed by renewal attempts. So we're not resolving them, we're just submitting new payments.
We pushed that above test to our staging environment to really test it out. If I see additional issues, I will reach back out in this thread.
gotcha!