#kiwi_best-practices
1 messages ¡ Page 1 of 1 (latest)
đ 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/1346100927165104149
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
Sample request id:
req_E79QmqNTcmLnLa
What do you mean by 'requirement payment'?
Collect payment info even if there's nothing to pay?
if you open a session, and make the cost free, it doesn't require the user to supply their payment details
exactly!
Got it, you can configure that yes: https://docs.stripe.com/api/checkout/sessions/create#create_checkout_session-payment_method_collection
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Oh, wait. It's a payment mode session
yeah, the flow is that we ask the customer to pay for a one time setup fee
we save their payment details, and then later start a subscription off_session
which is why we need them to supply their details
We changed this in an API version prior to the one you're using: https://docs.stripe.com/upgrades#2023-08-16
and the coupon would make the setup fee free, but we still need the details
this is the relevant part right:
"No-cost orders are now enabled for one-time payments in Checkout Sessions. The value of payment_method_collection has changed from always to if_required accordingly."
so are you suggesting that I can use the field with always, and that should make it required?
The issue is you can't set payment_method_collection in mode: 'payment' sessions and the default is, in the API version you're using, if_required so we hide the field as there's nothing to pay
so unfortunately this feature is unavailable for now, I will probably receive an error if I try to set it to always
Yes
alright, our workaround is currently to make them pay 1$ I suppose that is the best we can do for now. Thank you for your help!
You'd need to use an API version that predates 2023-08-16 which isn't really recommnded