#k3x_

1 messages ยท Page 1 of 1 (latest)

coarse hollyBOT
covert depot
#

๐Ÿ‘‹ happy to help, please give me a moment to read through your message

#

which makes an attached payment method on a customer object be the default one used for any subscription for this customer

arctic cosmos
#

Well yes but I don't know how to get the customer's payment method

covert depot
#

you're migrating from one account to another?

arctic cosmos
#

Yes

covert depot
#

there are a couple of ways to handle that

#

either you need to contact https://support.stripe.com/?contact=true and ask for help migrating your customers/payment methods

arctic cosmos
#

I already did copy my customers and their payment methods are associated with them

#

here is an example

covert depot
arctic cosmos
#

Their payment methods are here but not default
So I have to make a loop for all my customers

arctic cosmos
covert depot
#

oh fair point

#

now I understand what you need

arctic cosmos
#

So I get an array
I get the first method
Assign it as default

#

and therefore for all customers
But how about the new customers, how to set as default automatically

covert depot
arctic cosmos
#

Ok thank you very much