#christian-genco_api

1 messages ¡ Page 1 of 1 (latest)

flat furnaceBOT
ocean sageBOT
#

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.

flat furnaceBOT
#

👋 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/1215391786558693477

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

fading lance
#

The strange thing is that this code is working:

  let stripe_user_id = null;
  try {
    const stripeResponse = await stripe.oauth.token({
      grant_type: "authorization_code",
      code,
    });
    logger.info("stripeResponse", stripeResponse);
    stripe_user_id = stripeResponse.stripe_user_id;
  } catch (err) {
    throw new HttpsError("unknown", `Stripe error: ${err.message}`);
  }

stripe_user_id gets populated with my client's Stripe account's user ID (acct_1D69heHq1WHDe8ig).

When I try to make a request on behalf of that client I get the error Error: The provided key 'sk_live_*********************************************************************************************avpJ5v' does not have access to account 'acct_1D69heHq1WHDe8ig' (or that account does not exist). Application access may have been revoked.

ocean sageBOT
fading lance
#

I see the failed request in the Recent errors card on /developers but not in /logs so I'm not sure how to send you a related request ID.

hasty remnant
#

Looking at this

#

Can you copy and paste one of those failing request IDs?

fading lance
#

Sure, I don't think these are related to this issue though: req_LZaDtga542Gh01

hasty remnant
#

Ok, i had a suspicion but wanted to confirm

#

You're accidentally consuming the oauth token twice, this triggers deauthorization

fading lance
#

Ahh hah, interesting

#

oh I see the frontend bug causing that to be called twice

#

HAHAHA that worked, amazing. Thank you so much we've been struggling with that all day