Hey im trying to implement stripe webhooks with lambda functions and i can’t pass stripe signature validation : https://stripe.com/docs/webhooks/signatures
it seems the body is being modified somewhere and the validation fails
if i add a custom request template to get the raw body , serverless remove all other variables and i can’t handle the event with express
is there a way to “extend” a template instead of override it ? would like to add the raw body like this :
“rawbody”: “$util.escapeJavaScript($input.body)”,
I ran into the same issue while trying to implement stripe webhooks
To validate and process a stripe webhook, the raw body of the request and the stripe signature from the request header is required.The config in the snippet above will only provide the raw body.
The snippet below is enhances the mapping template to provide both raw body and request headers required to process stripe webhook events.