lightningd: include offer_id in invoice_creation notification#8981
Open
vincenzopalazzo wants to merge 1 commit intoElementsProject:masterfrom
Open
lightningd: include offer_id in invoice_creation notification#8981vincenzopalazzo wants to merge 1 commit intoElementsProject:masterfrom
vincenzopalazzo wants to merge 1 commit intoElementsProject:masterfrom
Conversation
d8b934a to
d014248
Compare
When a BOLT 12 invoice is created via createinvoice and is associated with a local offer, include the offer_id in the invoice_creation event notification. This allows plugins to determine which offer triggered an invoice creation without having to call listinvoices for every created invoice. For bolt11 invoices and bolt12 invoices not associated with a local offer, the field is omitted. Fixes ElementsProject#8191 Changelog-Added: The `invoice_creation` notification now includes `offer_id` when the invoice is associated with a BOLT 12 offer.
d014248 to
7519749
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
invoice_creationevent notification now includes anoffer_idfield when the invoice is associated with a BOLT 12 offerinvoice_creationand immediately identifying which offer triggered the invoiceFixes #8191
Test plan
invoice_creationnotification includesoffer_idwhen a bolt12 invoice is created viacreateinvoicefor a known local offeroffer_idis absent for regular bolt11 invoices