#devil_code
1 messages ยท Page 1 of 1 (latest)
๐ 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/1266319584039014462
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
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.
- devil_api, 2 days ago, 19 messages
- devil_webhooks, 2 days ago, 10 messages
Hello, not sure if this is a "code" question/help
I retrieve a charge with:
String(dispute.charge),
{},
{ stripeAccount: stripeAccountId }
)
the dispute comes from a webhook event, which comes alr
not sure if the customers.retrieve part is good though
๐ happy to help
๐ , it might even be the stripe.charges request
the error means that process.env.STRIPE_SECRET_KEY is an empty string
so we're sure that this code:
String(dispute.charge),
{},
{ stripeAccount: stripeAccountId }
)```
wouldnt do it?
I'm not sure what you're trying to do to be honest, but first you need to fix the bigger issue which is the API authentication
i have bunch of methods in the webhook event, and the "requests" are throwing, and was not sure where, checking NR logs, it was thrown this.
Is the API auth related to the process.env.STRIPE_SECRET_KEY?
yes
stripe = new Stripe(process.env.STRIPE_SECRET_KEY as string, {
apiVersion: '2023-10-16',
})
this line initiates the stripe instance
i'm also not sure why you're using this.stripe
instead of stripe
oh and btw it's not stripe= new Stripe('....') it's stripe = Stripe('.....')