doc: list the error codes of funding_* commands

Changelog-None
This commit is contained in:
Vasil Dimov 2020-01-05 16:40:17 +01:00 committed by ZmnSCPxj, ZmnSCPxj jxPCSmnZ
parent 11da88a281
commit 89466f0e55
6 changed files with 69 additions and 10 deletions

View file

@ -10,12 +10,15 @@ lightning-fundchannel_cancel - Command for completing channel establishment
\fBfundchannel_cancel\fR is a lower level RPC command\. It allows channel funder \fBfundchannel_cancel\fR is a lower level RPC command\. It allows channel funder
to cancel a channel before funding broadcast with a connected peer\. to cancel a channel before funding broadcast with a connected peer\.
\fIid\fR is the node id of the remote peer with which to cancel\. \fIid\fR is the node id of the remote peer with which to cancel\.
Note that the funding transaction MUST NOT be broadcast before Note that the funding transaction MUST NOT be broadcast before
\fBfundchannel_cancel\fR\. Broadcasting transaction before \fBfundchannel_cancel\fR \fBfundchannel_cancel\fR\. Broadcasting transaction before \fBfundchannel_cancel\fR
WILL lead to unrecoverable loss of funds\. WILL lead to unrecoverable loss of funds\.
If \fBfundchannel_cancel\fR is called after \fBfundchannel_complete\fR, the remote If \fBfundchannel_cancel\fR is called after \fBfundchannel_complete\fR, the remote
peer may disconnect when command succeeds\. In this case, user need to connect peer may disconnect when command succeeds\. In this case, user need to connect
to remote peer again before opening channel\. to remote peer again before opening channel\.
@ -26,8 +29,18 @@ On success, returns confirmation that the channel establishment has been
canceled\. canceled\.
On failure, returns an error\. On error the returned object will contain \fBcode\fR and \fBmessage\fR properties,
with \fBcode\fR being one of the following:
.RS
.IP \[bu]
-32602: If the given parameters are wrong\.
.IP \[bu]
-1: Catchall nonspecific error\.
.IP \[bu]
306: Unknown peer id\.
.RE
.SH AUTHOR .SH AUTHOR
Lisa Neigut \fI<niftynei@gmail.com\fR> is mainly responsible\. Lisa Neigut \fI<niftynei@gmail.com\fR> is mainly responsible\.

View file

@ -28,7 +28,12 @@ RETURN VALUE
On success, returns confirmation that the channel establishment has been On success, returns confirmation that the channel establishment has been
canceled. canceled.
On failure, returns an error. On error the returned object will contain `code` and `message` properties,
with `code` being one of the following:
- -32602: If the given parameters are wrong.
- -1: Catchall nonspecific error.
- 306: Unknown peer id.
AUTHOR AUTHOR
------ ------

View file

@ -32,8 +32,20 @@ On success, returns a confirmation that \fIcommitments_secured\fR and the
derived \fIchannel_id\fR\. derived \fIchannel_id\fR\.
On failure, returns an error\. On error the returned object will contain \fBcode\fR and \fBmessage\fR properties,
with \fBcode\fR being one of the following:
.RS
.IP \[bu]
-32602: If the given parameters are wrong\.
.IP \[bu]
-1: Catchall nonspecific error\.
.IP \[bu]
305: Peer is not connected\.
.IP \[bu]
306: Unknown peer id\.
.RE
.SH AUTHOR .SH AUTHOR
Lisa Neigut \fI<niftynei@gmail.com\fR> is mainly responsible\. Lisa Neigut \fI<niftynei@gmail.com\fR> is mainly responsible\.
@ -47,7 +59,3 @@ lightning-fundchannel_\fBstart\fR(7), lightning-fundchannel_\fBcancel\fR(7)
Main web site: \fIhttps://github.com/ElementsProject/lightning\fR Main web site: \fIhttps://github.com/ElementsProject/lightning\fR
.HL
Last updated 2019-06-12 11:16:20 CEST

View file

@ -30,7 +30,13 @@ RETURN VALUE
On success, returns a confirmation that *commitments\_secured* and the On success, returns a confirmation that *commitments\_secured* and the
derived *channel\_id*. derived *channel\_id*.
On failure, returns an error. On error the returned object will contain `code` and `message` properties,
with `code` being one of the following:
- -32602: If the given parameters are wrong.
- -1: Catchall nonspecific error.
- 305: Peer is not connected.
- 306: Unknown peer id.
AUTHOR AUTHOR
------ ------

View file

@ -50,8 +50,26 @@ If a \fBclose_to\fR address was provided, will close to this address iff the \fB
returned in the response\. Otherwise, the peer does not support \fBoption_upfront_shutdownscript\fR\. returned in the response\. Otherwise, the peer does not support \fBoption_upfront_shutdownscript\fR\.
On failure, returns an error\. On error the returned object will contain \fBcode\fR and \fBmessage\fR properties,
with \fBcode\fR being one of the following:
.RS
.IP \[bu]
-32602: If the given parameters are wrong\.
.IP \[bu]
-1: Catchall nonspecific error\.
.IP \[bu]
300: The amount exceeded the maximum configured funding amount\.
.IP \[bu]
301: The provided \fBpush_msat\fR is greater than the provided \fBamount\fR\.
.IP \[bu]
304: Still syncing with bitcoin network
.IP \[bu]
305: Peer is not connected\.
.IP \[bu]
306: Unknown peer id\.
.RE
.SH AUTHOR .SH AUTHOR
Lisa Neigut \fI<niftynei@gmail.com\fR> is mainly responsible\. Lisa Neigut \fI<niftynei@gmail.com\fR> is mainly responsible\.

View file

@ -45,7 +45,16 @@ On success, returns the *funding\_address* and the *scriptpubkey* for the channe
If a `close_to` address was provided, will close to this address iff the `close_to` address is If a `close_to` address was provided, will close to this address iff the `close_to` address is
returned in the response. Otherwise, the peer does not support `option_upfront_shutdownscript`. returned in the response. Otherwise, the peer does not support `option_upfront_shutdownscript`.
On failure, returns an error. On error the returned object will contain `code` and `message` properties,
with `code` being one of the following:
- -32602: If the given parameters are wrong.
- -1: Catchall nonspecific error.
- 300: The amount exceeded the maximum configured funding amount.
- 301: The provided `push_msat` is greater than the provided `amount`.
- 304: Still syncing with bitcoin network
- 305: Peer is not connected.
- 306: Unknown peer id.
AUTHOR AUTHOR
------ ------