#Omri-checkout-redirect
1 messages ยท Page 1 of 1 (latest)
yup, it's expired. They're only for 24 hours after creation
You can extend this if you need: https://stripe.com/docs/payments/checkout/managing-limited-inventory#setting-an-expiration-time
I use it only 1 or 2 second after I create it, maybe I did something wrong?
Oh my bad. It's been completed
why?
I work according : https://stripe.com/docs/payments/bacs-debit/connect/accept-a-payment
Because you've (or somebody) used the Checkout Session URL and completed the flow
They're one-time use
I need to call to redirectToCheckout before the user complete the flow?
ohh I think I understand
You need to create a new Checkout Session in this case
And then you can pass the ID to redirectToCheckout
I did it in different way, I just did window.location.href = session.url;
it is good way or I need to change it?
Nope that's fine too
ok ๐
when I call to session = Stripe::Checkout::Session.retrieve({ id: params[:session_id], stripe_account: @direct_debit.entity.stripe_uid, })
Stripe::Checkout::Session.retrieve(params[:session_id], {
stripe_account: @direct_debit.entity.stripe_uid,
})
๐
it is not what write here https://stripe.com/docs/payments/bacs-debit/connect/accept-a-payment#retrieve-session
Good spot! I'll fix, thanks!
๐