Verify and handle incoming UQPAY webhook events with the Node.js SDK.
The SDK provides a constructEvent method that verifies the webhook signature and returns a typed event object. This ensures the payload has not been tampered with and was sent by UQPAY.
Use a raw body parser for your webhook route. Do not use express.json() — the signature verification requires the original request body as a string or Buffer.