#maverickyd_unexpected
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/1265600817612853340
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
๐ happy to help
if you're using a SetupIntent this means that you're not collecting any payment
so if you're doing that to setup a new subscription this is highly not recommended
instead you need to follow the steps in this guide https://docs.stripe.com/billing/subscriptions/build-subscriptions
so you should start by creating the subscription and then using the latest_invoice.payment_intent to confirm the payment
Understood, but since this setup is deeply integrated with our business, and I agree there are better ways to be done, it requires a lot of rework and refactor. My question was more like if it is possible to provide the amount in a similar way like it was updated for the React Native package, where you can pass amount and label even to confirming setup intents: https://github.com/stripe/stripe-react-native/pull/1511/files
well there a few different options here. Is this for a subscription specifically, like a trial period? What does the amount you want to use represent? And to be clear, you mention React Native and Flutter, but you're actually implementing this on the web right?
Yes, I am implementing on the web, just referenced React Native because I found a similar problem there and seems to have been resolved. The use case is a payment form for a donation ( one time or recurring) and the amount charged is know before hand since it is part of the cart object. Simplified flow is: Fill out payment form -> receive tokenized payment method -> Call to backend for all the business logic -> Call to Stripe to initiate a PaymentIntent with autoconfirm
I don't see why you need a SetupIntent for that. I'd suggest trying to build it as a flow where you only create a PaymentIntent.
We have deferred/two-step flows that likely accomodate your business logic step.
https://docs.stripe.com/payments/build-a-two-step-confirmation (and you can see how amount and currency can be passed to the PaymentElement options, and those are used for what the wallet popups show).
Got it, thank you