Webhooks()

Webhooks

new Webhooks()

To Do:
  • Refactor this into a service

Methods

async, static error(req, err, invoice)

Use to send a webhook when an error has occurred.
Parameters:
Name Type Description
req The ExpressJS Request
err The Error thrown
invoice The invoice

async broadcasted(invoice)

Use to send a webhook when a transactoin is broadcasted to the network.
Parameters:
Name Type Description
invoice The Invoice

async broadcasting(invoice)

Use to send a webhook when a transaction is broadcasting to the network.
Parameters:
Name Type Description
invoice The Invoice

async confirmed(invoice)

Use to send a webhook when a transactoin is broadcasted to the network.
Parameters:
Name Type Description
invoice The Invoice

async requested(invoice)

Use to send a webhook when an invoice is requested.
Parameters:
Name Type Description
invoice The Invoice