Webhooks are HTTP notifications sent from Lago to your application.
The messages are sent as a POST request to every webhook endpoint defined in
the settings of your Lago organization.If you return an error (any response other than a 2xx) or if there is a network
issue, the message is sent again. Lago attempts each message 3 times, waiting
longer between each attempt.
Along with the payload, the message carries the X-Lago-Signature and X-Lago-Signature-Algorithm HTTP headers.They ensure the message comes from Lago and has not been altered.To verify the signature, decode it and compare the result with the body of the webhook.You choose between two signature algorithms when you create a webhook endpoint, hmac or jwt. The
default is jwt.