Skip to content

Commit 3a37880

Browse files
committed
f: Update InvoiceRequestReceived docs
1 parent f00047b commit 3a37880

File tree

1 file changed

+15
-4
lines changed

1 file changed

+15
-4
lines changed

lightning/src/events/mod.rs

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -823,18 +823,29 @@ pub enum Event {
823823
addresses: Vec<msgs::SocketAddress>,
824824
},
825825

826-
/// Event triggered when manual handling is enabled, and an invoice request is received.
826+
/// Event triggered when manual handling is enabled and an invoice request is received.
827+
///
828+
/// Indicates that an [`InvoiceRequest`] for an [`Offer`] created by us has been received.
829+
///
830+
/// This event will only be generated if [`UserConfig::manually_handle_bolt12_messages`] is set.
831+
/// Use [`ChannelManager::send_invoice_request_response`] to respond with an appropriate
832+
/// response to the received invoice request. Use [`ChannelManager::reject_invoice_request`] to
833+
/// reject the invoice request and respond with an [`InvoiceError`]. See the docs for further details.
834+
///
835+
/// [`Offer`]: crate::offers::offer::Offer
836+
/// [`UserConfig::manually_handle_bolt12_messages`]: crate::util::config::UserConfig::manually_handle_bolt12_messages
837+
/// [`ChannelManager::send_invoice_request_response`]: crate::ln::channelmanager::ChannelManager::send_invoice_request_response
838+
/// [`ChannelManager::reject_invoice_request`]: crate::ln::channelmanager::ChannelManager::reject_invoice_request
839+
/// [`InvoiceError`]: crate::offers::invoice_error::InvoiceError
827840
InvoiceRequestReceived {
828-
/// The invoice request to pay.
841+
/// The received invoice request to respond to.
829842
invoice_request: InvoiceRequest,
830843
/// The context of the [`BlindedMessagePath`] used to send the invoice request.
831844
///
832845
/// [`BlindedMessagePath`]: crate::blinded_path::message::BlindedMessagePath
833846
context: Option<OffersContext>,
834847
/// A responder for replying with an [`InvoiceError`] if needed.
835848
///
836-
/// `None` if the invoice wasn't sent with a reply path.
837-
///
838849
/// [`InvoiceError`]: crate::offers::invoice_error::InvoiceError
839850
responder: Responder,
840851
},

0 commit comments

Comments
 (0)