#dev-josue_docs

1 messages ¡ Page 1 of 1 (latest)

graceful perchBOT
#

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

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

onyx arrow
#

hi there!

trail arrow
#

*My custom logic

onyx arrow
#

Is it strictly required to always send Stripe response code 200 on stripe webhooks?
if you don't, Stripe will resend you the event a few times, untill you reply with a 200.

trail arrow
#

@onyx arrow , basically, 200 response from the webhook indicates that it receives the event from stripe. Thus, the stripe will not send it again the event. Am I right?

onyx arrow
#

yep. Stripe sends you the event. if you reply back with 200, then that's it. if you don't reply at all or reply a different with a different status code, Stripe assume you didn't receive the event, so it will try again.

trail arrow
#

About this https://docs.stripe.com/webhooks#handle-events-asynchronously, it is recommended to put complex logic on async and reply as soon as possible the 200 status code. The error on complex/custom logic is up to us how to handle it asynchronously. As long we already send 200 status code to stripe to indicate we receive it.

Did I get it right?

Create an event destination to receive events at an HTTPS webhook endpoint. Receiving webhook events is particularly useful for listening to asynchronous events such as when a customer's bank confirms a payment, a customer disputes a charge, a recurring payment succeeds, or when collecting subscription payments.

onyx arrow
#

if you don't send a 200 reply within 20 seconds, Stripe will assume you didn't get the event and will resend it. to avoid this, we recommend to immediately return a 200 response.

graceful perchBOT