diff --git a/doc/developers-guide/plugin-development/event-notifications.md b/doc/developers-guide/plugin-development/event-notifications.md index 3e7532594..964f8f26a 100644 --- a/doc/developers-guide/plugin-development/event-notifications.md +++ b/doc/developers-guide/plugin-development/event-notifications.md @@ -114,12 +114,14 @@ A notification for topic `invoice_payment` is sent every time an invoice is paid "invoice_payment": { "label": "unique-label-for-invoice", "preimage": "0000000000000000000000000000000000000000000000000000000000000000", - "amount_msat": 10000 + "msat": 10000, } } ``` +Before version `23.11` the `msat` field was a string with msat-suffix, e.g: `"10000msat"`. + Note that there will be a string member "outpoint" ("txid:outnum") if the payment was onchain (possible with the *invoices-onchain-fallback* config option). diff --git a/doc/developers-guide/plugin-development/hooks.md b/doc/developers-guide/plugin-development/hooks.md index 3e31959be..66f66087f 100644 --- a/doc/developers-guide/plugin-development/hooks.md +++ b/doc/developers-guide/plugin-development/hooks.md @@ -163,12 +163,11 @@ This hook is called whenever a valid payment for an unpaid invoice has arrived. "payment": { "label": "unique-label-for-invoice", "preimage": "0000000000000000000000000000000000000000000000000000000000000000", - "amount_msat": 10000 + "msat": 10000 } } ``` - - +Before version `23.11` the `msat` field was a string with msat-suffix, e.g: `"10000msat"`. The hook is deliberately sparse, since the plugin can use the JSON-RPC `listinvoices` command to get additional details about this invoice. It can return a `failure_message` field as defined for final nodes in [BOLT 4](https://github.com/lightning/bolts/blob/master/04-onion-routing.md#failure-messages), a `result` field with the string `reject` to fail it with `incorrect_or_unknown_payment_details`, or a `result` field with the string `continue` to accept the payment.