├── HELP.md ├── README.md └── mark.sh /HELP.md: -------------------------------------------------------------------------------- 1 | ## NAME 2 | lncli - control plane for your Lightning Network Daemon (lnd) 3 | 4 | ## USAGE 5 | lncli [global options] command [command options] [arguments...] 6 | 7 | ## VERSION 8 | 0.9.0-beta commit=v0.9.0-beta-155-g1467cd4dd382f9de7dc7ee89d779324ee9d2b4da 9 | 10 | ## COMMANDS 11 | |command|description| 12 | | --- | --- | 13 | |getinfo |Returns basic information related to the active daemon.| 14 | |debuglevel |Set the debug level.| 15 | |stop |Stop and shutdown the daemon.| 16 | |help, h|Shows a list of commands or help for one command| 17 | 18 | #### Channels 19 | |command|description| 20 | | --- | --- | 21 | |openchannel |Open a channel to a node or an existing peer.| 22 | |closechannel |Close an existing channel.| 23 | |closeallchannels |Close all existing channels.| 24 | |abandonchannel |Abandons an existing channel.| 25 | |channelbalance |Returns the sum of the total available channel balance across all open channels.| 26 | |pendingchannels |Display information pertaining to pending channels.| 27 | |listchannels |List all open channels.| 28 | |closedchannels |List all closed channels.| 29 | |getchaninfo |Get the state of a channel.| 30 | |getnetworkinfo |Get statistical information about the current state of the network.| 31 | |feereport |Display the current fee policies of all active channels.| 32 | |updatechanpolicy |Update the channel policy for all channels, or a single channel.| 33 | |exportchanbackup |Obtain a static channel back up for a selected channels, or all known channels| 34 | |verifychanbackup |Verify an existing channel backup| 35 | |restorechanbackup |Restore an existing single or multi-channel static channel backup| 36 | 37 | #### Macaroons 38 | |command|description| 39 | | --- | --- | 40 | |bakemacaroon |Bakes a new macaroon with the provided list of permissions and restrictions| 41 | 42 | #### On-chain 43 | |command|description| 44 | | --- | --- | 45 | |estimatefee |Get fee estimates for sending bitcoin on-chain to multiple addresses.| 46 | |sendmany |Send bitcoin on-chain to multiple addresses.| 47 | |sendcoins |Send bitcoin on-chain to an address.| 48 | |listunspent |List utxos available for spending.| 49 | |listchaintxns |List transactions from the wallet.| 50 | 51 | #### Payments 52 | |command|description| 53 | | --- | --- | 54 | |sendpayment |Send a payment over lightning.| 55 | |payinvoice |Pay an invoice over lightning.| 56 | |sendtoroute |Send a payment over a predefined route.| 57 | |addinvoice |Add a new invoice.| 58 | |lookupinvoice |Lookup an existing invoice by its payment hash.| 59 | |listinvoices |List all invoices currently stored within the database. Any active debug invoices are ignored.| 60 | |listpayments |List all outgoing payments.| 61 | |queryroutes |Query a route to a destination.| 62 | |decodepayreq |Decode a payment request.| 63 | |fwdinghistory |Query the history of all forwarded HTLCs.| 64 | 65 | #### Peers 66 | |command|description| 67 | | --- | --- | 68 | |connect |Connect to a remote lnd peer.| 69 | |disconnect |Disconnect a remote lnd peer identified by public key.| 70 | |listpeers |List all active, currently connected peers.| 71 | |describegraph |Describe the network graph.| 72 | |getnodeinfo |Get information on a specific node.| 73 | 74 | #### Startup 75 | |command|description| 76 | | --- | --- | 77 | |create |Initialize a wallet when starting lnd for the first time.| 78 | |unlock |Unlock an encrypted wallet at startup.| 79 | |changepassword |Change an encrypted wallet's password at startup.| 80 | 81 | #### Wallet 82 | |command|description| 83 | | --- | --- | 84 | |newaddress |Generates a new address.| 85 | |walletbalance |Compute and display the wallet's current balance.| 86 | |signmessage |Sign a message with the node's private key.| 87 | |verifymessage |Verify a message signed with the signature.| 88 | 89 | #### Watchtower 90 | |command|description| 91 | | --- | --- | 92 | |wtclient |Interact with the watchtower client.| 93 | 94 | ## GLOBAL OPTIONS 95 | |option|description| 96 | | --- | --- | 97 | |--rpcserver value |host:port of ln daemon (default: "localhost:10009")| 98 | |--lnddir value |path to lnd's base directory (default: "/home/tomosaigon/.lnd")| 99 | |--tlscertpath value |path to TLS certificate (default: "/home/tomosaigon/.lnd/tls.cert")| 100 | |--chain value, -c value |the chain lnd is running on e.g. bitcoin (default: "bitcoin")| 101 | |--network value, -n value|the network lnd is running on e.g. mainnet, testnet, etc. (default: "mainnet")| 102 | |--no-macaroons |disable macaroon authentication| 103 | |--macaroonpath value |path to macaroon file| 104 | |--macaroontimeout value |anti-replay macaroon validity time in seconds (default: 60)| 105 | |--macaroonip value |if set, lock macaroon to specific IP address| 106 | |--help, -h |show help| 107 | |--version, -v |print the version| 108 | 109 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## NAME 2 | lncli - control plane for your Lightning Network Daemon (lnd) 3 | 4 | ## USAGE 5 | lncli [global options] command [command options] [arguments...] 6 | 7 | ## VERSION 8 | 0.8.2-beta commit=queue/v1.0.2-81-gf5b1d40b9af062179b5c77cf0b3e6414a8a0751d 9 | 10 | ## COMMANDS 11 | |command|description| 12 | | --- | --- | 13 | |getinfo |Returns basic information related to the active daemon.| 14 | |debuglevel |Set the debug level.| 15 | |stop |Stop and shutdown the daemon.| 16 | |help, h|Shows a list of commands or help for one command| 17 | 18 | #### Channels 19 | |command|description| 20 | | --- | --- | 21 | |openchannel |Open a channel to a node or an existing peer.| 22 | |closechannel |Close an existing channel.| 23 | |closeallchannels |Close all existing channels.| 24 | |abandonchannel |Abandons an existing channel.| 25 | |channelbalance |Returns the sum of the total available channel balance across all open channels.| 26 | |pendingchannels |Display information pertaining to pending channels.| 27 | |listchannels |List all open channels.| 28 | |closedchannels |List all closed channels.| 29 | |getchaninfo |Get the state of a channel.| 30 | |getnetworkinfo |Get statistical information about the current state of the network.| 31 | |feereport |Display the current fee policies of all active channels.| 32 | |updatechanpolicy |Update the channel policy for all channels, or a single channel.| 33 | |exportchanbackup |Obtain a static channel back up for a selected channels, or all known channels| 34 | |verifychanbackup |Verify an existing channel backup| 35 | |restorechanbackup |Restore an existing single or multi-channel static channel backup| 36 | 37 | #### Macaroons 38 | |command|description| 39 | | --- | --- | 40 | |bakemacaroon |Bakes a new macaroon with the provided list of permissions and restrictions| 41 | 42 | #### On-chain 43 | |command|description| 44 | | --- | --- | 45 | |estimatefee |Get fee estimates for sending bitcoin on-chain to multiple addresses.| 46 | |sendmany |Send bitcoin on-chain to multiple addresses.| 47 | |sendcoins |Send bitcoin on-chain to an address.| 48 | |listunspent |List utxos available for spending.| 49 | |listchaintxns |List transactions from the wallet.| 50 | 51 | #### Payments 52 | |command|description| 53 | | --- | --- | 54 | |sendpayment |Send a payment over lightning.| 55 | |payinvoice |Pay an invoice over lightning.| 56 | |sendtoroute |Send a payment over a predefined route.| 57 | |addinvoice |Add a new invoice.| 58 | |lookupinvoice |Lookup an existing invoice by its payment hash.| 59 | |listinvoices |List all invoices currently stored within the database. Any active debug invoices are ignored.| 60 | |listpayments |List all outgoing payments.| 61 | |queryroutes |Query a route to a destination.| 62 | |decodepayreq |Decode a payment request.| 63 | |fwdinghistory |Query the history of all forwarded HTLCs.| 64 | 65 | #### Peers 66 | |command|description| 67 | | --- | --- | 68 | |connect |Connect to a remote lnd peer.| 69 | |disconnect |Disconnect a remote lnd peer identified by public key.| 70 | |listpeers |List all active, currently connected peers.| 71 | |describegraph |Describe the network graph.| 72 | |getnodeinfo |Get information on a specific node.| 73 | 74 | #### Startup 75 | |command|description| 76 | | --- | --- | 77 | |create |Initialize a wallet when starting lnd for the first time.| 78 | |unlock |Unlock an encrypted wallet at startup.| 79 | |changepassword |Change an encrypted wallet's password at startup.| 80 | 81 | #### Wallet 82 | |command|description| 83 | | --- | --- | 84 | |newaddress |Generates a new address.| 85 | |walletbalance |Compute and display the wallet's current balance.| 86 | |signmessage |Sign a message with the node's private key.| 87 | |verifymessage |Verify a message signed with the signature.| 88 | 89 | #### Watchtower 90 | |command|description| 91 | | --- | --- | 92 | |wtclient |Interact with the watchtower client.| 93 | 94 | ## GLOBAL OPTIONS 95 | |option|description| 96 | | --- | --- | 97 | |--rpcserver value |host:port of ln daemon (default: "localhost:10009")| 98 | |--lnddir value |path to lnd's base directory (default: "/home/tomosaigon/.lnd")| 99 | |--tlscertpath value |path to TLS certificate (default: "/home/tomosaigon/.lnd/tls.cert")| 100 | |--chain value, -c value |the chain lnd is running on e.g. bitcoin (default: "bitcoin")| 101 | |--network value, -n value|the network lnd is running on e.g. mainnet, testnet, etc. (default: "mainnet")| 102 | |--no-macaroons |disable macaroon authentication| 103 | |--macaroonpath value |path to macaroon file| 104 | |--macaroontimeout value |anti-replay macaroon validity time in seconds (default: 60)| 105 | |--macaroonip value |if set, lock macaroon to specific IP address| 106 | |--help, -h |show help| 107 | |--version, -v |print the version| 108 | 109 | -------------------------------------------------------------------------------- /mark.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Usage: LNCLIPATH="" ./mark.sh > HELP.md 4 | $LNCLIPATH/lncli | sed \ 5 | -e 's/\(NAME\|USAGE\|VERSION\):/## \1/' \ 6 | -e 's/COMMANDS:/## COMMANDS\n\|command\|description\|\n\| --- \| --- \|/' \ 7 | -e 's/^ \([A-Za-z-]*\):$/#### \1\n\|command\|description\|\n\| --- \| --- \|/' \ 8 | -e 's/^ \([a-z][a-z]*,\{0,1\} \{0,1\}[a-z]*\) *\(.*\)$/\|\1\|\2|/' \ 9 | -e 's/GLOBAL OPTIONS:/## GLOBAL OPTIONS\n\|option\|description\|\n\| --- \| --- \|/' \ 10 | -e 's/^ --\(.*\) [ ]*\(.*\)/|--\1|\2|/' 11 | 12 | --------------------------------------------------------------------------------