#rlineweaver
1 messages · Page 1 of 1 (latest)
We have this about default_source in our docs:
If you are using payment methods created via the PaymentMethods API, see the invoice_settings.default_payment_method field instead.
What payment methods are you using?
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
hi @silver viper , I don't see our code interacting with /v1/payment_methods* APIs anywhere, though in the Stripe Dashboard I can see that the customer in question has a value in customer.invoice_settings.default_payment_method. Could that have gotten there via some other method (outside of our API interactions)? (like the Stripe Dashboard or the customer portal?)
If a Payment Method was created either through the Dashboard or Customer Portal it would save to the invoice_settings property rather than default_source
aha, yes, I have found an event log that indicates that it was set via the Customer portal. so does this mean that our code should be changed to set invoice_settings.default_payment_method in addition to / instead of default_source ?
(in our situation a customer can input a new credit card on our web site and we intend to set this as their default payment source for future payments, which I now believe is not working if the customer has ever entered a card via the Customer portal)
It's something you can update. Stripe will prefer the invoice_settings PM over the default_source if both are present. But it will fall back to default_source if no other is set.
thank you @silver viper , I think that answers my question!