#Quentin

1 messages · Page 1 of 1 (latest)

dim sparrowBOT
lapis flax
#

Hi there!

wheat otter
#

hi

lapis flax
#

I'm not sure I understand your question. Can you clarify?

wheat otter
#

I've made a subscription

#

with a credit card respecting the sca2 validation

#

it's okay for you?

lapis flax
#

What do you mean "it's okay for you"? What's your exact question?

wheat otter
#

I just asking if it's clear for you before I continue my explaination

#

I continue so

#

the subscription still working month after month

#

but the customer sees that is payment card is expiring, so he wants to add a new one to the subscription to avoid service cancelation

#

how do we change the card (paiement method)? Do we have to respect a new sca2 validation?

lapis flax
#

So you want to change the payment method used for an active subscription? Do you want to do that before or after that an invoice is created and failed?

wheat otter
#

before that an invoice is created

lapis flax
#

Got it. So you would need to create a SetupIntent to attach a new PaymentMethod to the customer, and then set it as the default payment method for that customer.

wheat otter
#

so

#

const setupIntent = await stripe.setupIntents.create({
payment_method_types: ['card'],
});

I get a client secret

I use stripeElement to validate the card with this client secret

#

now the customer has the new PM so i change the default paimentMethod on the subscription

#

that's it?

lapis flax