#basscar1408_code
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/1315757566902534154
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
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.
- basscar1408_code, 1 hour ago, 3 messages
That's because you can't pass an existing subscription to embedded checkout
It expects a checkout session secret
is it not possible to use stripe checkout embeded to pay for subscriptions like this https://docs.stripe.com/billing/subscriptions/build-subscriptions?platform=web&ui=embedded-form&locale=en-GB&client=react
and if so do you know how id get the correct secret
as on that link there is no information about getting the lcient secret
Yeah that's the same as what I sent. Only difference is subscription mode vs payment mode
When you create the checkout session server-side it'll have a client secret
You need to pass that back to your frontend
So step 1 shows creating the checkout session: https://docs.stripe.com/payments/accept-a-payment?platform=web&ui=embedded-form#create-checkout-session
You would want mode=subscription instead, but same principle applies
How can i then link that to my customers subscription as i can only charge for line items using that
You can't
The checkout session itself creates a subscription when the user checks out in the embedded form
If you use embedded checkout, you never create a subscription explicitly
So i can't use embedded checkout for billing subscriptions
You can
That's what the above guides do
You just do not need to create a subscription yourself
The checkout session creates one when the user completes checkout
ah ok, thank you and then will the embedded checkout also change once a montly payment is due ? e.g. a user pays for the first time and sets up the subscription and then next month they look and it will say they need to pay again
If you do a mode=subscription checkout and use a recurring price, then subscription will be created after the user checks out
so recurring payments will happen automatically
great thank you so much