mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-11-19 09:54:16 +01:00
invoice: change default expiry to 7 days.
For online services, shorter may be fine, but for casual use I'm usually in a different timezone than the payer, so needs to be at least 1 day. Certainly 1 hr is short if they have to open a channel. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
77b859eaec
commit
1d6584e733
@ -15,6 +15,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
### Changed
|
||||
|
||||
- JSON API: `invoice` expiry defaults to 7 days.
|
||||
|
||||
### Deprecated
|
||||
|
||||
Note: You should always set `allow-deprecated-apis=false` to test for
|
||||
|
@ -2,12 +2,12 @@
|
||||
.\" Title: lightning-invoice
|
||||
.\" Author: [see the "AUTHOR" section]
|
||||
.\" Generator: DocBook XSL Stylesheets v1.79.1 <http://docbook.sf.net/>
|
||||
.\" Date: 02/23/2019
|
||||
.\" Date: 04/10/2019
|
||||
.\" Manual: \ \&
|
||||
.\" Source: \ \&
|
||||
.\" Language: English
|
||||
.\"
|
||||
.TH "LIGHTNING\-INVOICE" "7" "02/23/2019" "\ \&" "\ \&"
|
||||
.TH "LIGHTNING\-INVOICE" "7" "04/10/2019" "\ \&" "\ \&"
|
||||
.\" -----------------------------------------------------------------
|
||||
.\" * Define some portability stuff
|
||||
.\" -----------------------------------------------------------------
|
||||
@ -42,7 +42,7 @@ The \fIlabel\fR must be a unique string or number (which is treated as a string,
|
||||
.sp
|
||||
The \fIdescription\fR is a short description of purpose of payment, e\&.g\&. \fI1 cup of coffee\fR\&. This value is encoded into the BOLT11 invoice and is viewable by any node you send this invoice to\&. It must be UTF\-8, and cannot use \fI\eu\fR JSON escape codes\&.
|
||||
.sp
|
||||
The \fIexpiry\fR is optionally the number of seconds the invoice is valid for\&. If no value is provided the default of 3600 (1 Hour) is used\&.
|
||||
The \fIexpiry\fR is optionally the number of seconds the invoice is valid for\&. If no value is provided the default of 604800 (1 week) is used\&.
|
||||
.sp
|
||||
The \fIfallbacks\fR array is one or more fallback addresses to include in the invoice (in order from most\-preferred to least): note that these arrays are not currently tracked to fulfill the invoice\&.
|
||||
.sp
|
||||
|
@ -35,7 +35,7 @@ and is viewable by any node you send this invoice to. It must be
|
||||
UTF-8, and cannot use '\u' JSON escape codes.
|
||||
|
||||
The 'expiry' is optionally the number of seconds the invoice is valid for.
|
||||
If no value is provided the default of 3600 (1 Hour) is used.
|
||||
If no value is provided the default of 604800 (1 week) is used.
|
||||
|
||||
The 'fallbacks' array is one or more fallback addresses to include in
|
||||
the invoice (in order from most-preferred to least): note that these
|
||||
|
@ -415,7 +415,7 @@ static struct command_result *json_invoice(struct command *cmd,
|
||||
p_req("msatoshi", param_msat_or_any, &msatoshi_val),
|
||||
p_req("label", param_label, &info->label),
|
||||
p_req("description", param_escaped_string, &desc_val),
|
||||
p_opt_def("expiry", param_u64, &expiry, 3600),
|
||||
p_opt_def("expiry", param_u64, &expiry, 3600*24*7),
|
||||
p_opt("fallbacks", param_array, &fallbacks),
|
||||
p_opt("preimage", param_tok, &preimagetok),
|
||||
p_opt("exposeprivatechannels", param_bool, &exposeprivate),
|
||||
|
Loading…
Reference in New Issue
Block a user