FreeBSD Manual Pages
LIGHTNING-DECODEPAY(7) LIGHTNING-DECODEPAY(7) NAME lightning-decodepay -- Command for decoding a bolt11 string (low-level) SYNOPSIS decodepay bolt11 [description] DESCRIPTION Command added in v23.05. WARNING: deprecated: use decode which also handles bolt12. The decodepay RPC command checks and parses a bolt11 string as speci- fied by the BOLT 11 specification. • bolt11 (string): Bolt11 invoice to decode. • description (string, optional): Description of the invoice to de- code. RETURN VALUE On success, an object is returned, containing: • currency (string): The BIP173 name for the currency. • created_at (u64): The UNIX-style timestamp of the invoice. • expiry (u64): The number of seconds this is valid after timestamp. • payee (pubkey): The public key of the recipient. • payment_hash (hash): The hash of the payment_preimage. • signature (signature): Signature of the payee on this invoice. • min_final_cltv_expiry (u32): The minimum CLTV delay for the final node. • amount_msat (msat, optional): Amount the invoice asked for. • description (string, optional): The description of the purpose of the purchase. • description_hash (hash, optional): The hash of the description, in place of description. • payment_secret (hash, optional): The secret to hand to the payee node. • features (hex, optional): The features bitmap for this invoice. • payment_metadata (hex, optional): The payment_metadata to put in the payment. • fallbacks (array of objects, optional): Onchain addresses.: • type (string) (one of "P2PKH", "P2SH", "P2WPKH", "P2WSH", "P2TR"): The address type (if known). • hex (hex): Raw encoded address. • addr (string, optional): The address in appropriate format for type. • routes (array of arrays, optional): Route hints to the payee.: • (array of objects): Hops in the route. • pubkey (pubkey): The public key of the node. • short_channel_id (short_channel_id): A channel to the next peer. • fee_base_msat (msat): The base fee for payments. • fee_proportional_millionths (u32): The parts-per-million fee for payments. • cltv_expiry_delta (u32): The CLTV delta across this hop. • extra (array of objects, optional): Any extra fields we didn't know how to parse.: • tag (string) (always 1 characters): The bech32 letter which iden- tifies this field. • data (string): The bech32 data for this field. Technically, the description field is optional if a description_hash field is given, but in this case decodepay will only succeed if the op- tional description field is passed and matches the description_hash. In practice, these are currently unused. AUTHOR Rusty Russell <<rusty@rustcorp.com.au>> is mainly responsible. SEE ALSO lightning-pay(7), lightning-getroute(7), lightning-sendpay(7) RESOURCES BOLT #11 <https://github.com/lightning/bolts/blob/master/11-payment- encoding.md> Main web site: <https://github.com/ElementsProject/lightning> EXAMPLES Example 1: Request: $ lightning-cli decodepay -k "bolt11"="lnbcrt100n1pnt2bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000" { "id": "example:decodepay#1", "method": "decodepay", "params": { "bolt11": "lnbcrt100n1pnt2bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000bolt11invl010100000000" } } Response: { "currency": "bcrt", "created_at": 1738000000, "expiry": 604800, "payee": "nodeid010101010101010101010101010101010101010101010101010101010101", "amount_msat": 10000, "description": "l11 description", "min_final_cltv_expiry": 5, "payment_secret": "paymentsecretinvl00110001100011000110001100011000110001100011000", "features": "02024100", "routes": [ [ { "pubkey": "nodeid020202020202020202020202020202020202020202020202020202020202", "short_channel_id": "109x1x1", "fee_base_msat": 1, "fee_proportional_millionths": 10, "cltv_expiry_delta": 6 } ] ], "payment_hash": "paymenthashinvl0110011001100110011001100110011001100110011001100", "signature": "dcdepay30c4bb50bed209d020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202" } Core Lightning v25.02 LIGHTNING-DECODEPAY(7)
NAME | SYNOPSIS | DESCRIPTION | RETURN VALUE | AUTHOR | SEE ALSO | RESOURCES | EXAMPLES
Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=lightning-decodepay&sektion=7&manpath=FreeBSD+Ports+14.3.quarterly>
