#MadMac
1 messages · Page 1 of 1 (latest)
Payment Links is re-usable, i.e. same link can be paid multiple times and isn't meant for a specific customer, so customer can't be set
Ok. Is there any way that I can make the checkout session last longer than 24 hours?
I'm afraid it's not possible. expires_at can only allows up to 24 hours: https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-expires_at
I'd recommend creating a new Checkout Session if the URL is expired
What happens for the user if they go to an expired CS?
I guess I can just get the button to send them to one of my pages and create a new session then but that is quite a bit slower.
Any way to check if it is expired from the browser JS SDK?
What happens for the user if they go to an expired CS?
The payment page will show that the payment link is expired and customer can't be paid on that specific link
Expecting that > 50% will click within 24hrs
Any way to check if it is expired from the browser JS SDK?
I'm afraid it's not possible. There are two possible ways to check if a Checkout Session is expired:
- Store
expires_atin your own database for a Checkout Session ID to determine if it has been expired - Make a server request to retrieve the Checkout Session to check Checkout Session status: https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-status