#guccisofloppy
1 messages · Page 1 of 1 (latest)
req_liJZ3DVUx73t2J
Hello! Looking...
thanks!
The request itself looks fine, but the error is accurate.
The issue isn't with the request, it's with the associated Customer.
okay, cool, this brings up a follow-up question
basically, the client I'm working for has set up the same subscription with 2 different billing cycles as seperate products... why does the previous paymentIntent not translate to the new subscription?
If I add the new subscription, then delete the old one using subscriptionItems, I don't get this error
So, in this example, the customer has signed up for Product A, given us a valid payment method, decided they want to use a different billing cycle and switches to product B. If I add product B to the subscription object using subscriptionItems, and then delete product A, this goes off without a hitch, but swapping out the products using the code suggested at https://stripe.com/docs/billing/subscriptions/upgrade-downgrade results in this error
I think I get why the error is occuring, it just seems weird that doing it the "wrong" way avoids the error
It sounds like you need to set the Payment Method as the default for Invoices on the Customer: https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method
is the best way to do that during the checkout process or after the user has completed the purchase by listening for a "subscription created" webhook?
You should do this when you create the Checkout Session, before the payment.