Webhooks

BoomPay SDK provides an Express middleware for webhook handling. Each webhook event comes with a signature in the request header to verify the authenticity of the event.

The BoomPay SDK handles this verification process automatically when you use the provided boomPay.webhooks() function.
app.get('/webhook/success', boomPay.webhooks({
  apiKey: 'your-api-key',
}), (req, res) => {
  return res.status(200).send('OK');
});