#hazim-setupintent-defaultpm

1 messages · Page 1 of 1 (latest)

true drumBOT
plush trail
#

hazim-setupintent-defaultpm

#

@livid echo unfortunately that feature doesn't exist. I also with it did 😦

#

so you have to write code that will set it as the default after completion, usually in your webhook handler

livid echo
#

You should definetly add it

#

it's easier for us

#

can yo show me in the documentation where I can add it as a webhook

#

I am just afraid it wont be easy for the user to activate and set it as a default payment

plush trail
#

I don't disagree, just never been prioritized (lots of things to build)

#

I'm not sure I get the question you have about the doc. Are you the developer yourself?

livid echo
#

Yes

plush trail
#

Okay so have you written a webhook handler before? What's the context of your ask? Why are you trying to set a default PM. Are you using Billing/Subscriptions?

livid echo
#

I had an issue because Stripe doesnt launch the payment if there isn't a default payment method in the customer profile

#

Yes I have sub with 3 trial days , but first the user needs to enter a valid paymet method , and at the end of the trial , Stripe executes the payment with the setup

#

But I noticed that Stripe didn't execute the payment because there was a payment method but it was not set as default

#

SO what I want is to set the setup intent as a default payment

#

hope I was clear

plush trail
#

Okay so you are using Billing?

#

Can you give me an example Subscription id sub_123

livid echo
#

of course wait

#

sub_1MluonAPPDApV1IHilkNAGyM

#

here it is

plush trail
#

looking

#

that one had a SetupIntent already, if you had used that one it would have made the new PaymentMethod the default automatically

#

But otherwise: as the developer, you need to write code that listens to setup_intent.suceeded in your webhook handler, and then you set the PaymentMethod as the default at that point

livid echo
#

I think it's clear what should I do

#

web hook that listens to setup intent

#

I will see what I can do and get back to you

#

thank you for your help

plush trail
#

sure thing!