#khadim-yaseen_api

1 messages ¡ Page 1 of 1 (latest)

inland nimbusBOT
#

👋 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/1297872022549954591

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

steel citrus
#

hi! hmm you can't really avoid it, that's the design of the API, you get an incomplete subscription so you can easily retry the payment with the customer on the frontend. Why do you want to avoid it exactly?

vagrant timber
#

I was looking at this parameter in stripe docs for susbcription:
payment_behavior : error_if_incomplete.

#

Will this help, for not creating subscription if payment fails?

steel citrus
#

it does, but then it makes it impossible to handle 3D Secure authentication, which is quite common.

#

so that's why I suggest not using that and instead using the incomplete status as its the intended and recommended integration, and if there's a reason it doesn't work for you I could try to help with that

vagrant timber
#

when I receive the webhook customer.subscription.created, the status is always incomplete. Then the subscription gets updated, and becomes active. The workaround is to check all the customer.subscription.updated, but that is more processing than should be

steel citrus
#

I disagree with the "should be", seems like just a quick if-statement?

#

if(event.data.object.status == "incomplete") { continue/return} etc

inland nimbusBOT
vagrant timber
#

Okay thanks for the help