#jakob-evangelista_error
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.
- jakob-evangelista_best-practices, 1 day ago, 8 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/1242943700779405375
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
What is the Checkout Session that you're seeing in the developer console within the browser when this attempts to load?
cs_test_a14IwQhS8FAaSdF353Q2zNlLFl13aW4KPYmsrMPDVbnWA7VWQIB3QtD0Cf_secret_fidwbEhqYWAnPydgaGdgYWFgYScpJ2lkfGpwcVF8dWAnPyd2bGtiaWBabHFgaCcpJ3dgYWx3YGZxSmtGamh1aWBxbGprJz8nZGlyZHx2J3gl
^that is the checkout session
^^^
Most likely the issue is that this is a Checkout Session created on your Connect account acct_1PIv7ZRW5BKHkZ7f, but you're creating the Embedded Checkout Session using your platform's acct_1NYR21Dwy6WMuJi4 API key.
You need to specify the stripeAccount when you initialize Stripe on the client-side: https://docs.stripe.com/connect/authentication#adding-the-connected-account-id-to-a-client-side-application
Yes, but you have to instantiate the Stripe object somewhere, so look around for loadStripe and follow the example I linked to. That will most likely solve the issue
i initialized loadstripe here, is this correct?
Yup
That line where you call loadStripe() with your publishable API key is the one where you would need to add the Connect Account's ID
THANK YOU SO MUCH, your steps here solved it, is there a way I can initialize loadstripe on the server and then access it on the client? or is that not a thing? also, im assuming its safe to have the connect account id on the client correct?
It's safe to have the Account ID around. That can't really be used for anything
I'm not sure if you can initialize loadStripe() on the server, but I don't think you can. I seem to recall this being asked before and there was no way to do that since you have to load stripe.js from the browser/client