#Mahesh K

1 messages ยท Page 1 of 1 (latest)

shadow questBOT
eternal eagle
#

๐Ÿ‘‹ Hi there, Happy to help!

pastel grove
#

hi

#

i getting the folloing error when i update the my database when i catch an event from the stripe webhook

#

StripeAuthenticationError: You did not provide an API key. You need to provide your API key in the Authorization header, using Bearer auth (e.g. 'Authorization: Bearer YOUR_SECRET_KEY'). See https://stripe.com/docs/api#authentication for details, or we can help at https://support.stripe.com/.
at res.toJSON.then.Error_1.StripeAPIError.message

eternal eagle
pastel grove
#

yes i did

#

req_thtjKcxeh7egAg

eternal eagle
eternal eagle
pastel grove
#

yeah the above one

#

here is my code

#

case 'invoice.payment_succeeded':
console.log(event.data.object)
const final_invoice = event.data.object
console.log(final_invoice.payment_intent)
const payment_intent_details = await stripe.paymentIntents.retrieve(
final_invoice.payment_intent
);

  console.log(payment_intent_details)
#

it is the one of case in the switch statement, where i am catching the invoice.payment_succeeded event and in that response i have payment intent id, and by using it i am retriving the payment intent details

eternal eagle
#

This is the code. I need the requestId of the api call generated from that code.

pastel grove
#

req_thtjKcxeh7egAg

#

this the req id

#

are you there?

eternal eagle
pastel grove
#

yess

#

but i am getting the above error

#

๐Ÿ˜ข

eternal eagle
#

No, if you are getting error, that means in the request too you are seeing error.

shadow questBOT
pastel grove
#

hi'vanya

tender elbow
#

Hi! I'm taking over my colleague. Please, give me a moment to catch up.

pastel grove
#

ok

#

hi

tender elbow
#

Could you please summarise the latest question? Thanks!