#sg_api
1 messages ¡ Page 1 of 1 (latest)
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.
- sg_code, 51 minutes ago, 10 messages
- sg_api, 8 hours ago, 15 messages
- sg_connect-integration, 22 hours ago, 13 messages
- sg_docs, 1 day ago, 6 messages
đ 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/1239968623104102462
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
Can you be more specific? What was the URL that gave you that error? How did you redirect?
window.location.href = https://checkout.stripe.com/pay/cs_live_${sessionId};
remove cs_live_ from the HREF
The Session ID already includes it
This is the actual ID --> cs_test_a1npoGbRlmZlzHJXZcfT6FgdQI2RT22DqLoMNYHuhdzxeSieJyTZ49ELUO
Not this --> cs_live_cs_test_a1npoGbRlmZlzHJXZcfT6FgdQI2RT22DqLoMNYHuhdzxeSieJyTZ49ELUO
okey thanks ... but am I in the right way? I ask this because after we go in production I still work.
The URL should not work with a Checkout Session ID that starts with cs_live_cs_test
sorry I mean. am i on the right path which way to use sessionId.I have the same error even if i delete cs_live
just:window.location.href = https://checkout.stripe.com/pay/${sessionId}.
thanks a lot for your help
window.location.href = https://checkout.stripe.com/pay/${sessionId};
I'm not sure what you're doing here. A live mode Checkout Session ID looks like this --> cs_live_abc123
A test mod Checkout Session ID looks like this --> cs_test_abc123
So your URL should contain an ID that looks something like those
Also, you don't need to build the URL yourself. The Checkout Session object contains a url attribute with the full URL already made for you
cool...thank you two_shoes