From 3e79cffd6e06c2bf43240628c6371c36af530426 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Thu, 18 Feb 2021 10:26:19 +1030 Subject: [PATCH] doc: add disableoffer and listoffers manpages. I noticed that offer(7) referred to `deloffer` which doesn't exist. Signed-off-by: Rusty Russell --- doc/Makefile | 2 + doc/index.rst | 2 + doc/lightning-disableoffer.7 | 64 +++++++++++++++++++++++++++++ doc/lightning-disableoffer.7.md | 65 +++++++++++++++++++++++++++++ doc/lightning-listoffers.7 | 71 ++++++++++++++++++++++++++++++++ doc/lightning-listoffers.7.md | 73 +++++++++++++++++++++++++++++++++ doc/lightning-offer.7 | 4 +- doc/lightning-offer.7.md | 2 +- doc/lightning-offerout.7 | 4 +- doc/lightning-offerout.7.md | 2 +- 10 files changed, 283 insertions(+), 6 deletions(-) create mode 100644 doc/lightning-disableoffer.7 create mode 100644 doc/lightning-disableoffer.7.md create mode 100644 doc/lightning-listoffers.7 create mode 100644 doc/lightning-listoffers.7.md diff --git a/doc/Makefile b/doc/Makefile index 4bd029617..1c9ec80d2 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -21,6 +21,7 @@ MANPAGES := doc/lightning-cli.1 \ doc/lightning-delinvoice.7 \ doc/lightning-delpay.7 \ doc/lightning-dev-sendcustommsg.7 \ + doc/lightning-disableoffer.7 \ doc/lightning-disconnect.7 \ doc/lightning-feerates.7 \ doc/lightning-fetchinvoice.7 \ @@ -38,6 +39,7 @@ MANPAGES := doc/lightning-cli.1 \ doc/lightning-listforwards.7 \ doc/lightning-listfunds.7 \ doc/lightning-listinvoices.7 \ + doc/lightning-listoffers.7 \ doc/lightning-listpays.7 \ doc/lightning-listpeers.7 \ doc/lightning-listsendpays.7 \ diff --git a/doc/index.rst b/doc/index.rst index c634e8d42..6bfd1d280 100644 --- a/doc/index.rst +++ b/doc/index.rst @@ -44,6 +44,7 @@ c-lightning Documentation lightning-delinvoice lightning-delpay lightning-dev-sendcustommsg + lightning-disableoffer lightning-disconnect lightning-feerates lightning-fetchinvoice @@ -66,6 +67,7 @@ c-lightning Documentation lightning-listfunds lightning-listinvoices lightning-listnodes + lightning-listoffers lightning-listpays lightning-listpeers lightning-listsendpays diff --git a/doc/lightning-disableoffer.7 b/doc/lightning-disableoffer.7 new file mode 100644 index 000000000..1b1547e38 --- /dev/null +++ b/doc/lightning-disableoffer.7 @@ -0,0 +1,64 @@ +.TH "LIGHTNING-DISABLEOFFER" "7" "" "" "lightning-disableoffer" +.SH NAME +lightning-disableoffer - Command for removing an offer +.SH SYNOPSIS + +\fB(WARNING: experimental-offers only)\fR + + +\fBdisableoffer\fR \fIoffer_id\fR + +.SH DESCRIPTION + +The \fBdisableoffer\fR RPC command disables an offer, so that no further +invoices will be given out (if made with \fBlightning-offer\fR(7)) or +invoices accepted (if made with \fBlightning-offerout\fR(7))\. + + +We currently don't support deletion of offers, so offers are not +forgotten entirely (there may be invoices which refer to this offer)\. + +.SH EXAMPLE JSON REQUEST +.nf +.RS +{ + "id": 82, + "method": "disableoffer", + "params": { + "offer_id": "713a16ccd4eb10438bdcfbc2c8276be301020dd9d489c530773ba64f3b33307d ", + } +} +.RE + +.fi +.SH RETURN VALUE + +If successful the command returns an object, in the same format as \fBlistoffers\fR\. +The "active" field will always be false\. + +.SH EXAMPLE JSON RESPONSE +.nf +.RS +{ + "offer_id": "053a5c566fbea2681a5ff9c05a913da23e45b95d09ef5bd25d7d408f23da7084", + "active": false, + "single_use": false, + "bolt12": "lno1qgsqvgnwgcg35z6ee2h3yczraddm72xrfua9uve2rlrm9deu7xyfzrcgqvqcdgq2z9pk7enxv4jjqen0wgs8yatnw3ujz83qkc6rvp4j28rt3dtrn32zkvdy7efhnlrpr5rp5geqxs783wtlj550qs8czzku4nk3pqp6m593qxgunzuqcwkmgqkmp6ty0wyvjcqdguv3pnpukedwn6cr87m89t74h3auyaeg89xkvgzpac70z3m9rn5xzu28c", + "used": false +} +.RE + +.fi +.SH AUTHOR + +Rusty Russell \fI is mainly responsible\. + +.SH SEE ALSO + +\fBlightning-offer\fR(7), \fBlightning-offerout\fR(7), \fBlightning-listoffers\fR(7)\. + +.SH RESOURCES + +Main web site: \fIhttps://github.com/ElementsProject/lightning\fR + +\" SHA256STAMP:55cfb050fa2d28f58750dc74659d9f7bc5ec00499e218ccffd058db51efc38d2 diff --git a/doc/lightning-disableoffer.7.md b/doc/lightning-disableoffer.7.md new file mode 100644 index 000000000..398fd0438 --- /dev/null +++ b/doc/lightning-disableoffer.7.md @@ -0,0 +1,65 @@ +lightning-disableoffer -- Command for removing an offer +======================================================= + +SYNOPSIS +-------- +**(WARNING: experimental-offers only)** + +**disableoffer** *offer\_id* + +DESCRIPTION +----------- + +The **disableoffer** RPC command disables an offer, so that no further +invoices will be given out (if made with lightning-offer(7)) or +invoices accepted (if made with lightning-offerout(7)). + +We currently don't support deletion of offers, so offers are not +forgotten entirely (there may be invoices which refer to this offer). + +EXAMPLE JSON REQUEST +------------ +```json +{ + "id": 82, + "method": "disableoffer", + "params": { + "offer_id": "713a16ccd4eb10438bdcfbc2c8276be301020dd9d489c530773ba64f3b33307d ", + } +} +``` + +RETURN VALUE +------------ + +If successful the command returns an object, in the same format as **listoffers**. +The "active" field will always be false. + +EXAMPLE JSON RESPONSE +----- +```json +{ + "offer_id": "053a5c566fbea2681a5ff9c05a913da23e45b95d09ef5bd25d7d408f23da7084", + "active": false, + "single_use": false, + "bolt12": "lno1qgsqvgnwgcg35z6ee2h3yczraddm72xrfua9uve2rlrm9deu7xyfzrcgqvqcdgq2z9pk7enxv4jjqen0wgs8yatnw3ujz83qkc6rvp4j28rt3dtrn32zkvdy7efhnlrpr5rp5geqxs783wtlj550qs8czzku4nk3pqp6m593qxgunzuqcwkmgqkmp6ty0wyvjcqdguv3pnpukedwn6cr87m89t74h3auyaeg89xkvgzpac70z3m9rn5xzu28c", + "used": false +} + +``` + + +AUTHOR +------ + +Rusty Russell <> is mainly responsible. + +SEE ALSO +-------- + +lightning-offer(7), lightning-offerout(7), lightning-listoffers(7). + +RESOURCES +--------- + +Main web site: diff --git a/doc/lightning-listoffers.7 b/doc/lightning-listoffers.7 new file mode 100644 index 000000000..86c94f95e --- /dev/null +++ b/doc/lightning-listoffers.7 @@ -0,0 +1,71 @@ +.TH "LIGHTNING-LISTOFFERS" "7" "" "" "lightning-listoffers" +.SH NAME +lightning-listoffers - Command for listing offers +.SH SYNOPSIS + +\fB(WARNING: experimental-offers only)\fR + + +\fBlistoffers\fR [\fIoffer_id\fR] [\fIactive_only\fR] + +.SH DESCRIPTION + +The \fBlistoffers\fR RPC command list all offers, or with \fBoffer_id\fR, +only the offer with that offer_id (if it exists)\. If \fBactive_only\fR is +set and is true, only offers with \fBactive\fR true are returned\. + +.SH EXAMPLE JSON REQUEST +.nf +.RS +{ + "id": 82, + "method": "listoffers", + "params": { + "active_only": false + } +} +.RE + +.fi +.SH RETURN VALUE + +On success, an array \fIoffers\fR of objects is returned\. Each object contains +\fIoffer_id\fR, \fIactive\fR, \fIsingle_use\fR, \fIbolt12\fR and \fIused\fR\. + +.SH EXAMPLE JSON RESPONSE +.nf +.RS +{ + "offers": [ + { + "offer_id": "053a5c566fbea2681a5ff9c05a913da23e45b95d09ef5bd25d7d408f23da7084", + "active": true, + "single_use": false, + "bolt12": "lno1qgsqvgnwgcg35z6ee2h3yczraddm72xrfua9uve2rlrm9deu7xyfzrcgqvqcdgq2z9pk7enxv4jjqen0wgs8yatnw3ujz83qkc6rvp4j28rt3dtrn32zkvdy7efhnlrpr5rp5geqxs783wtlj550qs8czzku4nk3pqp6m593qxgunzuqcwkmgqkmp6ty0wyvjcqdguv3pnpukedwn6cr87m89t74h3auyaeg89xkvgzpac70z3m9rn5xzu28c", + "used": false + }, + { + "offer_id": "3247d3597fec19e362ca683416a48a0f76a44c1600725a7ee1936548feadacca", + "active": true, + "single_use": false, + "bolt12": "lno1qgsqvgnwgcg35z6ee2h3yczraddm72xrfua9uve2rlrm9deu7xyfzrcxqd24x3qgqgqlgzs3gdhkven9v5sxvmmjype82um50ys3ug9kxsmqdvj3c6ut2cuu2s4nrf8k2dulccgaqcdzxgp583utjlu49rcyqt8hc3s797umxn3r9367rdqc577rma7key58fywkajxnuzyapge86hj2pg80rjrma40xdqrxnsnva5l3ce7hz4ua8wf755dees4y9vnq", + "used": false + } + ] +} +.RE + +.fi +.SH AUTHOR + +Rusty Russell \fI is mainly responsible\. + +.SH SEE ALSO + +\fBlightning-offer\fR(7), \fBlightning-offerout\fR(7), \fBlightning-listoffers\fR(7)\. + +.SH RESOURCES + +Main web site: \fIhttps://github.com/ElementsProject/lightning\fR + +\" SHA256STAMP:f654c090c24a1cae9a3947b4ba0bfd051949502a5de6d78d899a7f6cf73a8fe6 diff --git a/doc/lightning-listoffers.7.md b/doc/lightning-listoffers.7.md new file mode 100644 index 000000000..d25b548c0 --- /dev/null +++ b/doc/lightning-listoffers.7.md @@ -0,0 +1,73 @@ +lightning-listoffers -- Command for listing offers +======================================================= + +SYNOPSIS +-------- +**(WARNING: experimental-offers only)** + +**listoffers** \[*offer_id*\] \[*active_only*\] + +DESCRIPTION +----------- + +The **listoffers** RPC command list all offers, or with `offer_id`, +only the offer with that offer_id (if it exists). If `active_only` is +set and is true, only offers with `active` true are returned. + +EXAMPLE JSON REQUEST +------------ +```json +{ + "id": 82, + "method": "listoffers", + "params": { + "active_only": false + } +} +``` + +RETURN VALUE +------------ + +On success, an array *offers* of objects is returned. Each object contains +*offer_id*, *active*, *single_use*, *bolt12* and *used*. + +EXAMPLE JSON RESPONSE +----- +```json +{ + "offers": [ + { + "offer_id": "053a5c566fbea2681a5ff9c05a913da23e45b95d09ef5bd25d7d408f23da7084", + "active": true, + "single_use": false, + "bolt12": "lno1qgsqvgnwgcg35z6ee2h3yczraddm72xrfua9uve2rlrm9deu7xyfzrcgqvqcdgq2z9pk7enxv4jjqen0wgs8yatnw3ujz83qkc6rvp4j28rt3dtrn32zkvdy7efhnlrpr5rp5geqxs783wtlj550qs8czzku4nk3pqp6m593qxgunzuqcwkmgqkmp6ty0wyvjcqdguv3pnpukedwn6cr87m89t74h3auyaeg89xkvgzpac70z3m9rn5xzu28c", + "used": false + }, + { + "offer_id": "3247d3597fec19e362ca683416a48a0f76a44c1600725a7ee1936548feadacca", + "active": true, + "single_use": false, + "bolt12": "lno1qgsqvgnwgcg35z6ee2h3yczraddm72xrfua9uve2rlrm9deu7xyfzrcxqd24x3qgqgqlgzs3gdhkven9v5sxvmmjype82um50ys3ug9kxsmqdvj3c6ut2cuu2s4nrf8k2dulccgaqcdzxgp583utjlu49rcyqt8hc3s797umxn3r9367rdqc577rma7key58fywkajxnuzyapge86hj2pg80rjrma40xdqrxnsnva5l3ce7hz4ua8wf755dees4y9vnq", + "used": false + } + ] +} + +``` + + +AUTHOR +------ + +Rusty Russell <> is mainly responsible. + +SEE ALSO +-------- + +lightning-offer(7), lightning-offerout(7), lightning-listoffers(7). + +RESOURCES +--------- + +Main web site: diff --git a/doc/lightning-offer.7 b/doc/lightning-offer.7 index 96eacf645..f9a87203f 100644 --- a/doc/lightning-offer.7 +++ b/doc/lightning-offer.7 @@ -143,10 +143,10 @@ Rusty Russell \fI is mainly responsible\. .SH SEE ALSO -\fBlightning-offerout\fR(7), \fBlightning-listoffers\fR(7), \fBlightning-deloffer\fR(7)\. +\fBlightning-offerout\fR(7), \fBlightning-listoffers\fR(7), \fBlightning-disableoffer\fR(7)\. .SH RESOURCES Main web site: \fIhttps://github.com/ElementsProject/lightning\fR -\" SHA256STAMP:02cc4efba11ccd75e34161583ab1b45c99e90aa7d4c122d9773d9acd775578fb +\" SHA256STAMP:4ab9701b01ad474482f7aa8d31ea2c1170904402c2f222f6d5a9ba826e963457 diff --git a/doc/lightning-offer.7.md b/doc/lightning-offer.7.md index 5f91b17e5..d9de6c6f8 100644 --- a/doc/lightning-offer.7.md +++ b/doc/lightning-offer.7.md @@ -116,7 +116,7 @@ Rusty Russell <> is mainly responsible. SEE ALSO -------- -lightning-offerout(7), lightning-listoffers(7), lightning-deloffer(7). +lightning-offerout(7), lightning-listoffers(7), lightning-disableoffer(7). RESOURCES --------- diff --git a/doc/lightning-offerout.7 b/doc/lightning-offerout.7 index ae8a6960b..edc2ec9c9 100644 --- a/doc/lightning-offerout.7 +++ b/doc/lightning-offerout.7 @@ -104,10 +104,10 @@ Rusty Russell \fI is mainly responsible\. .SH SEE ALSO -\fBlightning-offer\fR(7), \fBlightning-listoffers\fR(7), \fBlightning-deloffer\fR(7)\. +\fBlightning-offer\fR(7), \fBlightning-listoffers\fR(7), \fBlightning-disableoffer\fR(7)\. .SH RESOURCES Main web site: \fIhttps://github.com/ElementsProject/lightning\fR -\" SHA256STAMP:f8055a0a7ee1ba79b1358e190e9e10e0825a1c3b2af5f85f133fe693fa8b1ea4 +\" SHA256STAMP:87487dd8a47b745a98d107e1de7cb3eac0421f3ccaf44a4d2a938fa19f6261c0 diff --git a/doc/lightning-offerout.7.md b/doc/lightning-offerout.7.md index 2df8d686b..8b7266a60 100644 --- a/doc/lightning-offerout.7.md +++ b/doc/lightning-offerout.7.md @@ -85,7 +85,7 @@ Rusty Russell <> is mainly responsible. SEE ALSO -------- -lightning-offer(7), lightning-listoffers(7), lightning-deloffer(7). +lightning-offer(7), lightning-listoffers(7), lightning-disableoffer(7). RESOURCES ---------