Function FlashControlAPI.payInvoice

Attempt to find a payment path for the invoice and pay for the invoice.

abstract void payInvoice (
  PublicKey reg_pk,
  Invoice invoice
) @safe;

If a payment path cannot be found, or if the payment fails along the payment path then the listener will be notified through the onPaymentFailure endpoint.

If the payment succeeds the onPaymentSuccess endpoint will be called on the listener.

Parameters

NameDescription
reg_pk the registered public key. If this key is not managed by this Flash node then an error will be returned.
invoice the invoice to pay