#luca-didomenico_webhooks

1 messages ยท Page 1 of 1 (latest)

hardy needleBOT
#

๐Ÿ‘‹ 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/1292767474399449160

๐Ÿ“ Have more to share? Add more details, code, screenshots, videos, etc. below.

thorn hound
#

hi! well I'd start by adding extensive logs to log the payload variable, the signature header and the key, and checking all of those

uneven sluice
#

Hi! I already logged the WebHook Signing Secret and my Stripe Key, and confirmed they are correct by checking my dashboard

thorn hound
#

and the payload?

uneven sluice
thorn hound
#

I see on your account you have the same URL registered twice, in test and live mode. That would break this(because we will send you live and test events but your code can't know which it's recieving so it can't know which secret to use).

uneven sluice
#

ops, let me fix this

#

thanks for pointing it out

thorn hound
uneven sluice
#

I've removed the live mode URL

#

and resent the webhook from the dashboard

#

but still get the same error :/

thorn hound
#

sure but what signing secret is the actively-running code using

uneven sluice
#

the one in test mode

#

let me double check because I noticed something weird

#

give me a sec

#

the webhook secret was the error

#

I was changing it on my CDK stack definition

#

but I discovered that even if you change the value of an env variable but not its name, when you deploy the cdk stack the variable value is not updated

#

so now I created STRIPE_TEST_WEBHOOK_SECRET and STRIPE_LIVE_WEBHOOK_SECRET

#

thanks a lot!!

thorn hound
#

great!