diff --git a/doc/Makefile b/doc/Makefile index 9acb59785..f7834cdab 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -18,7 +18,10 @@ MANPAGES := doc/lightning-cli.1 \ doc/lightning-sendpay.7 \ doc/lightning-waitinvoice.7 \ doc/lightning-waitanyinvoice.7 \ - doc/lightning-waitsendpay.7 + doc/lightning-waitsendpay.7 \ + doc/lightning-newaddr.7 \ + doc/lightning-withdraw.7 \ + doc/lightning-listfunds.7 doc-all: $(MANPAGES) diff --git a/doc/lightning-listfunds.7 b/doc/lightning-listfunds.7 new file mode 100644 index 000000000..3c43140f4 --- /dev/null +++ b/doc/lightning-listfunds.7 @@ -0,0 +1,168 @@ +'\" t +.\" Title: lightning-listfunds +.\" Author: [see the "AUTHOR" section] +.\" Generator: DocBook XSL Stylesheets v1.79.1 +.\" Date: 04/26/2018 +.\" Manual: \ \& +.\" Source: \ \& +.\" Language: English +.\" +.TH "LIGHTNING\-LISTFUNDS" "7" "04/26/2018" "\ \&" "\ \&" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +lightning-listfunds \- Command showing all funds currently managed by the c\-lightning node\&. +.SH "SYNOPSIS" +.sp +\fBlistfunds\fR +.SH "DESCRIPTION" +.sp +The \fBlistfunds\fR RPC command displays all funds available, either in unspent outputs (UTXOs) in the internal wallet or funds locked in currently open channels\&. +.SH "RETURN VALUE" +.sp +On success two arrays will be returned: \fIoutputs\fR with funds currently locked onchain in UTXOs and \fIchannels\fR with funds readily spendable in channels\&. +.sp +Each entry in \fIoutputs\fR will include: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\fItxid\fR +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\fIaddress\fR +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\fIoutput\fR +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\fIvalue\fR +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\fIstatus\fR +.RE +.sp +Each entry in \fIchannels\fR will include: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\fIpeer_id\fR +\- the peer with which the channel is opened\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\fIshort_channel_id\fR +\- as per BOLT 7 (representing the block, transaction number and output index of the channel funding transaction)\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\fIchannel_sat\fR +\- available satoshis on our node\(cqs end of the channel (values rounded to the nearest satoshi as internal storage is in milisatoshi)\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\fIchannel_total_sat\fR +\- total channel value in satoshi (values rounded to the nearest satoshi as internal storage is in milisatoshi)\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\fIfunding_txid\fR +\- funding transaction id\&. +.RE +.SH "AUTHOR" +.sp +Felix is mainly responsible\&. +.SH "SEE ALSO" +.sp +lightning\-newaddr(7), lightning\-fundchannel(7), lightning\-withdraw(7) +.SH "RESOURCES" +.sp +Main web site: https://github\&.com/ElementsProject/lightning diff --git a/doc/lightning-listfunds.7.txt b/doc/lightning-listfunds.7.txt new file mode 100644 index 000000000..ddd55aa80 --- /dev/null +++ b/doc/lightning-listfunds.7.txt @@ -0,0 +1,63 @@ +LIGHTNING-LISTFUNDS(7) +====================== +:doctype: manpage + +NAME +---- +lightning-listfunds - Command showing all funds currently managed by +the c-lightning node. + +SYNOPSIS +-------- +*listfunds* + +DESCRIPTION +----------- +The *listfunds* RPC command displays all funds available, either in +unspent outputs (UTXOs) in the internal wallet or funds locked in +currently open channels. + +RETURN VALUE +------------ +On success two arrays will be returned: 'outputs' with funds +currently locked onchain in UTXOs and 'channels' with funds +readily spendable in channels. + +Each entry in 'outputs' will include: + +- 'txid' + +- 'address' + +- 'output' + +- 'value' + +- 'status' + +Each entry in 'channels' will include: + +- 'peer_id' - the peer with which the channel is opened. + +- 'short_channel_id' - as per BOLT 7 (representing the block, transaction +number and output index of the channel funding transaction). + +- 'channel_sat' - available satoshis on our node's end of the channel +(values rounded to the nearest satoshi as internal storage is in milisatoshi). + +- 'channel_total_sat' - total channel value in satoshi +(values rounded to the nearest satoshi as internal storage is in milisatoshi). + +- 'funding_txid' - funding transaction id. + +AUTHOR +------ +Felix is mainly responsible. + +SEE ALSO +-------- +lightning-newaddr(7), lightning-fundchannel(7), lightning-withdraw(7) + +RESOURCES +--------- +Main web site: https://github.com/ElementsProject/lightning diff --git a/doc/lightning-listpayments.7 b/doc/lightning-listpayments.7 index fd41ed47f..f86183a4c 100644 --- a/doc/lightning-listpayments.7 +++ b/doc/lightning-listpayments.7 @@ -2,12 +2,12 @@ .\" Title: lightning-listpayments .\" Author: [see the "AUTHOR" section] .\" Generator: DocBook XSL Stylesheets v1.79.1 -.\" Date: 01/18/2018 +.\" Date: 04/26/2018 .\" Manual: \ \& .\" Source: \ \& .\" Language: English .\" -.TH "LIGHTNING\-LISTPAYME" "7" "01/18/2018" "\ \&" "\ \&" +.TH "LIGHTNING\-LISTPAYME" "7" "04/26/2018" "\ \&" "\ \&" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- diff --git a/doc/lightning-newaddr.7 b/doc/lightning-newaddr.7 new file mode 100644 index 000000000..28fa937d6 --- /dev/null +++ b/doc/lightning-newaddr.7 @@ -0,0 +1,58 @@ +'\" t +.\" Title: lightning-newaddr +.\" Author: [see the "AUTHOR" section] +.\" Generator: DocBook XSL Stylesheets v1.79.1 +.\" Date: 04/26/2018 +.\" Manual: \ \& +.\" Source: \ \& +.\" Language: English +.\" +.TH "LIGHTNING\-NEWADDR" "7" "04/26/2018" "\ \&" "\ \&" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +lightning-newaddr \- Command for generating a new address to be used by c\-lightning\&. +.SH "SYNOPSIS" +.sp +\fBnewaddr\fR [ \fIp2sh\-segwit\fR | \fIbech32\fR ] +.SH "DESCRIPTION" +.sp +The \fBnewaddr\fR RPC command generates a new address which can subsequently be used to fund channels managed by the c\-lightning node\&. +.sp +The funding transaction needs to be confirmed before funds can be used\&. +.sp +The optional parameter specifies the type of address wanted i\&.e\&. p2sh\-segwit (e\&.g\&. 2MxaozoqWwiUcuD9KKgUSrLFDafLqimT9Ta on bitcoin testnet or 3MZxzq3jBSKNQ2e7dzneo9hy4FvNzmMmt3 on bitcoin mainnet) or bech32 (e\&.g\&. tb1qu9j4lg5f9rgjyfhvfd905vw46eg39czmktxqgg on bitcoin testnet or bc1qwqdg6squsna38e46795at95yu9atm8azzmyvckulcc7kytlcckxswvvzej on bitcoin mainnet)\&. +.sp +If not specified the address generated is p2sh\-segwit\&. +.SH "RETURN VALUE" +.sp +On success, a new address will be returned\&. +.SH "ERRORS" +.sp +If a non recognized address type is requested an error message will be returned +.SH "AUTHOR" +.sp +Felix is mainly responsible\&. +.SH "SEE ALSO" +.sp +lightning\-listfunds(7), lightning\-fundchannel(7), lightning\-withdraw(7) +.SH "RESOURCES" +.sp +Main web site: https://github\&.com/ElementsProject/lightning diff --git a/doc/lightning-newaddr.7.txt b/doc/lightning-newaddr.7.txt new file mode 100644 index 000000000..b72be9dc1 --- /dev/null +++ b/doc/lightning-newaddr.7.txt @@ -0,0 +1,47 @@ +LIGHTNING-NEWADDR(7) +==================== +:doctype: manpage + +NAME +---- +lightning-newaddr - Command for generating a new address to +be used by c-lightning. + +SYNOPSIS +-------- +*newaddr* [ 'p2sh-segwit' | 'bech32' ] + +DESCRIPTION +----------- +The *newaddr* RPC command generates a new address which can +subsequently be used to fund channels managed by the c-lightning node. + +The funding transaction needs to be confirmed before funds can be used. + +The optional parameter specifies the type of address wanted i.e. +p2sh-segwit (e.g. 2MxaozoqWwiUcuD9KKgUSrLFDafLqimT9Ta on bitcoin testnet +or 3MZxzq3jBSKNQ2e7dzneo9hy4FvNzmMmt3 on bitcoin mainnet) or bech32 +(e.g. tb1qu9j4lg5f9rgjyfhvfd905vw46eg39czmktxqgg on bitcoin testnet or +bc1qwqdg6squsna38e46795at95yu9atm8azzmyvckulcc7kytlcckxswvvzej on bitcoin mainnet). + +If not specified the address generated is p2sh-segwit. + +RETURN VALUE +------------ +On success, a new address will be returned. + +ERRORS +------ +If a non recognized address type is requested an error message will be returned + +AUTHOR +------ +Felix is mainly responsible. + +SEE ALSO +-------- +lightning-listfunds(7), lightning-fundchannel(7), lightning-withdraw(7) + +RESOURCES +--------- +Main web site: https://github.com/ElementsProject/lightning diff --git a/doc/lightning-withdraw.7 b/doc/lightning-withdraw.7 new file mode 100644 index 000000000..076ffaf5b --- /dev/null +++ b/doc/lightning-withdraw.7 @@ -0,0 +1,58 @@ +'\" t +.\" Title: lightning-withdraw +.\" Author: [see the "AUTHOR" section] +.\" Generator: DocBook XSL Stylesheets v1.79.1 +.\" Date: 04/26/2018 +.\" Manual: \ \& +.\" Source: \ \& +.\" Language: English +.\" +.TH "LIGHTNING\-WITHDRAW" "7" "04/26/2018" "\ \&" "\ \&" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +lightning-withdraw \- Command for withdrawing funds from the internal wallet\&. +.SH "SYNOPSIS" +.sp +\fBwithdraw\fR \fIdestination\fR \fIsatoshi\fR +.SH "DESCRIPTION" +.sp +The \fBwithdraw\fR RPC command sends funds from c\-lightning\(cqs internal wallet to the address specified in \fIdestination\fR\&. +.sp +The address can be of any Bitcoin accepted type, including bech32\&. +.sp +\fIsatoshi\fR is the amount to be withdrawn from the internal wallet (expressed, as name suggests, in satoshi)\&. The string \fIall\fR can be used to specify withdrawal of all available funds\&. +.SH "RETURN VALUE" +.sp +On success, an object with attributes \fItx\fR and \fItxid\fR will be returned\&. +.sp +\fItx\fR represents the raw bitcoin, fully signed, transaction and \fItxid\fR represent the bitcoin transaction id\&. +.SH "ERRORS" +.sp +If an incorrect address is supplied or the \fIsatoshi\fR parameter exceeds the amount in the internal wallet an error message will be returned\&. +.SH "AUTHOR" +.sp +Felix is mainly responsible\&. +.SH "SEE ALSO" +.sp +lightning\-listfunds(7), lightning\-fundchannel(7), lightning\-newaddr(7) +.SH "RESOURCES" +.sp +Main web site: https://github\&.com/ElementsProject/lightning diff --git a/doc/lightning-withdraw.7.txt b/doc/lightning-withdraw.7.txt new file mode 100644 index 000000000..8907d8c45 --- /dev/null +++ b/doc/lightning-withdraw.7.txt @@ -0,0 +1,52 @@ +LIGHTNING-WITHDRAW(7) +==================== +:doctype: manpage + +NAME +---- +lightning-withdraw - Command for withdrawing funds from the +internal wallet. + +SYNOPSIS +-------- +*withdraw* 'destination' 'satoshi' + +DESCRIPTION +----------- +The *withdraw* RPC command sends funds from c-lightning's +internal wallet to the address specified in 'destination'. + +The address can be of any Bitcoin accepted type, +including bech32. + +'satoshi' is the amount to be withdrawn from the internal +wallet (expressed, as name suggests, in satoshi). +The string 'all' can be used to specify withdrawal of all +available funds. + + +RETURN VALUE +------------ +On success, an object with attributes 'tx' and 'txid' will +be returned. + +'tx' represents the raw bitcoin, fully signed, transaction +and 'txid' represent the bitcoin transaction id. + +ERRORS +------ +If an incorrect address is supplied or the 'satoshi' +parameter exceeds the amount in the internal wallet +an error message will be returned. + +AUTHOR +------ +Felix is mainly responsible. + +SEE ALSO +-------- +lightning-listfunds(7), lightning-fundchannel(7), lightning-newaddr(7) + +RESOURCES +--------- +Main web site: https://github.com/ElementsProject/lightning