#kun_api

1 messages ¡ Page 1 of 1 (latest)

timber heathBOT
#

👋 Welcome to your new thread!

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1271545516584599605

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

mystic geyserBOT
#

Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

versed quarry
#

What's your question?

#

You passed payment_behavior: 'default_incomplete', when creating the sub

#

That's entirely expected

round plaza
#

my question is after I get my setupIntent approved by 3DS

I try to create subscription
But what I get is
subscription.latest_invoice.payment_intent.status = "required_confirmation"

and because of this I get incomplete status in my stripe dashboard
what should I do herE?

versed quarry
#

Why do you create a setupintent prior to creating the subscription?

round plaza
#

well the flow is

step 1: get user card details with stripe elements and then get paymentMethodId

step2: create customer

step 3: create setupIntent (because I want future payments)

step 4: in future pay the value that customer selected the plan and start subscription for recurring payments

versed quarry
#

Doing a setupintent before subscription can cause issues

round plaza
#

but why i try to subscribe
I get this
subscription.latest_invoice.payment_intent.status = "required_confirmation"

and hence my subscription goes "incomplete"

versed quarry
#

we don't recommend that flow

#

You collect payment method details on the subscription

round plaza
#

But I dont want to charge customer at once

#

I want to charge for example after 7-days trail

#

then I charge staright way and create a subscription

#

and Yes I want to do using custom form with stripe elements on frontend

versed quarry
#

You can do trial with above flow

#

You'd instead collect payment details via the setupintent generated from the subscription object

#

Not your own setupintent

#

Your current flow can cause issues with duplicate 3ds, etc

round plaza
#

Alright thanks let me try it

versed quarry
#

So the difference is if no trial, you use the client secret from the invoice's payment intent as shown in that guide I shared

#

If you have a trial on the sub, then you use the above setup intent's client secret