ListInvoices returns a list of all the invoices currently stored within the
database. Any active debug invoices are ignored. It has full support for
paginated responses, allowing users to query for specific invoices through
their add_index. This can be done by using either the first_index_offset or
last_index_offset fields included in the response as the index_offset of the
next request. By default, the first 100 invoices created will be returned.
Backwards pagination is also supported through the Reversed flag.
$ lncli listinvoices --help NAME: lncli listinvoices - List all invoices currently stored within the database. Any active debug invoices are ignored. USAGE: lncli listinvoices [command options][arguments...] CATEGORY: Invoices DESCRIPTION: This command enables the retrieval of all invoices currently stored within the database. It has full support for paginationed responses, allowing users to query for specific invoices through their add_index. This can be done by using either the first_index_offset or last_index_offset fields included in the response as the index_offset of the next request. Backward pagination is enabled by default to receive current invoices first. If you wish to paginate forwards, set the paginate-forwards flag. If none of the parameters are specified, then the last 100 invoices will be returned. For example: if you have 200 invoices, "lncli listinvoices" will return the last 100 created. If you wish to retrieve the previous 100, the first_offset_index of the response can be used as the index_offset of the next listinvoices request. OPTIONS: --pending_only toggles if all invoices should be returned, or only those that are currently unsettled --index_offset value the index of an invoice that will be used as either the start or end of a query to determine which invoices should be returned in the response (default: 0) --max_invoices value the max number of invoices to return(default: 0) --paginate-forwards if set, invoices succeeding the index_offset will be returned --creation_date_start value timestamp in seconds, if set, filter invoices with creation date greater than or equal to it (default: 0) --creation_date_end value timestamp in seconds, if set, filter invoices with creation dateless than or equal to it (default: 0)
The minimum number of real hops to include in a blinded path. This doesn't include our node, so if the minimum is 1, then the path will contain at minimum our node along with an introduction node hop. If it is zero then the shortest path will use our node as an introduction node.
uint32
integer
num_hops
The number of hops to include in a blinded path. This doesn't include our node, so if it is 1, then the path will contain our node along with an introduction node or dummy node hop. If paths shorter than NumHops is found, then they will be padded using dummy hops.
uint32
integer
max_num_paths
The maximum number of blinded paths to select and add to an invoice.
uint32
integer
node_omission_list
A list of node IDs of nodes that should not be used in any of our generated blinded paths.
An optional memo to attach along with the invoice. Used for record keeping purposes for the invoice's creator, and will also be set in the description field of the encoded payment request if the description_hash field is not being used.
string
string
r_preimage
The hex-encoded preimage (32 byte) which will allow settling an incoming HTLC payable to this preimage. When using REST, this field must be encoded as base64.
bytes
string
r_hash
The hash of the preimage. When using REST, this field must be encoded as base64. Note: Output only, don't specify for creating an invoice.
bytes
string
value
The value of this invoice in satoshis The fields value and value_msat are mutually exclusive.
int64
string
value_msat
The value of this invoice in millisatoshis The fields value and value_msat are mutually exclusive.
int64
string
settleddeprecated
Whether this invoice has been fulfilled. The field is deprecated. Use the state field instead (compare to SETTLED).
bool
boolean
creation_date
When this invoice was created. Measured in seconds since the unix epoch. Note: Output only, don't specify for creating an invoice.
int64
string
settle_date
When this invoice was settled. Measured in seconds since the unix epoch. Note: Output only, don't specify for creating an invoice.
int64
string
payment_request
A bare-bones invoice for a payment within the Lightning Network. With the details of the invoice, the sender has all the data necessary to send a payment to the recipient. Note: Output only, don't specify for creating an invoice.
string
string
description_hash
Hash (SHA-256) of a description of the payment. Used if the description of payment (memo) is too long to naturally fit within the description field of an encoded payment request. When using REST, this field must be encoded as base64.
bytes
string
expiry
Payment request expiry time in seconds. Default is 86400 (24 hours).
int64
string
fallback_addr
Fallback on-chain address.
string
string
cltv_expiry
Delta to use for the time-lock of the CLTV extended to the final hop.
uint64
string
route_hints
Route hints that can each be individually used to assist in reaching the invoice's destination.
Whether this invoice should include routing hints for private channels. Note: When enabled, if value and value_msat are zero, a large number of hints with these channels can be included, which might not be desirable.
bool
boolean
add_index
The "add" index of this invoice. Each newly created invoice will increment this index making it monotonically increasing. Callers to the SubscribeInvoices call can use this to instantly get notified of all added invoices with an add_index greater than this one. Note: Output only, don't specify for creating an invoice.
uint64
string
settle_index
The "settle" index of this invoice. Each newly settled invoice will increment this index making it monotonically increasing. Callers to the SubscribeInvoices call can use this to instantly get notified of all settled invoices with an settle_index greater than this one. Note: Output only, don't specify for creating an invoice.
uint64
string
amt_paiddeprecated
Deprecated, use amt_paid_sat or amt_paid_msat.
int64
string
amt_paid_sat
The amount that was accepted for this invoice, in satoshis. This will ONLY be set if this invoice has been settled or accepted. We provide this field as if the invoice was created with a zero value, then we need to record what amount was ultimately accepted. Additionally, it's possible that the sender paid MORE that was specified in the original invoice. So we'll record that here as well. Note: Output only, don't specify for creating an invoice.
int64
string
amt_paid_msat
The amount that was accepted for this invoice, in millisatoshis. This will ONLY be set if this invoice has been settled or accepted. We provide this field as if the invoice was created with a zero value, then we need to record what amount was ultimately accepted. Additionally, it's possible that the sender paid MORE that was specified in the original invoice. So we'll record that here as well. Note: Output only, don't specify for creating an invoice.
int64
string
state
The state the invoice is in. Note: Output only, don't specify for creating an invoice.
Indicates if this invoice was a spontaneous payment that arrived via keysend [EXPERIMENTAL]. Note: Output only, don't specify for creating an invoice.
bool
boolean
payment_addr
The payment address of this invoice. This is also called payment secret in specifications (e.g. BOLT 11). This value will be used in MPP payments, and also for newer invoices that always require the MPP payload for added end-to-end security. Note: Output only, don't specify for creating an invoice.
bytes
string
is_amp
Signals whether or not this is an AMP invoice.
bool
boolean
amp_invoice_state
[EXPERIMENTAL]: Maps a 32-byte hex-encoded set ID to the sub-invoice AMP state for the given set ID. This field is always populated for AMP invoices, and can be used along side LookupInvoice to obtain the HTLC information related to a given sub-invoice. Note: Output only, don't specify for creating an invoice.
Signals that the invoice should include blinded paths to hide the true identity of the recipient.
bool
boolean
blinded_path_config
Config values to use when creating blinded paths for this invoice. These can be used to override the defaults config values provided in by the global config. This field is only used if is_blinded is true.