lightning 4.13.0 → 4.13.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Versions
2
2
 
3
- ## 4.13.0
3
+ ## 4.13.1
4
4
 
5
5
  - Add `sendMessageToPeer` to send a peer to peer message to a connected peer
6
6
  - Add `subscribeToPeerMessages` to listen to messages from connected peers
@@ -35,6 +35,12 @@ service Invoices {
35
35
  settled, this call will succeed.
36
36
  */
37
37
  rpc SettleInvoice (SettleInvoiceMsg) returns (SettleInvoiceResp);
38
+
39
+ /*
40
+ LookupInvoiceV2 attempts to look up at invoice. An invoice can be refrenced
41
+ using either its payment hash, payment address, or set ID.
42
+ */
43
+ rpc LookupInvoiceV2 (LookupInvoiceMsg) returns (lnrpc.Invoice);
38
44
  }
39
45
 
40
46
  message CancelInvoiceMsg {
@@ -134,4 +140,33 @@ message SubscribeSingleInvoiceRequest {
134
140
 
135
141
  // Hash corresponding to the (hold) invoice to subscribe to.
136
142
  bytes r_hash = 2;
143
+ }
144
+
145
+ enum LookupModifier {
146
+ // The default look up modifier, no look up behavior is changed.
147
+ DEFAULT = 0;
148
+
149
+ /*
150
+ Indicates that when a look up is done based on a set_id, then only that set
151
+ of HTLCs related to that set ID should be returned.
152
+ */
153
+ HTLC_SET_ONLY = 1;
154
+
155
+ /*
156
+ Indicates that when a look up is done using a payment_addr, then no HTLCs
157
+ related to the payment_addr should be returned. This is useful when one
158
+ wants to be able to obtain the set of associated setIDs with a given
159
+ invoice, then look up the sub-invoices "projected" by that set ID.
160
+ */
161
+ HTLC_SET_BLANK = 2;
162
+ }
163
+
164
+ message LookupInvoiceMsg {
165
+ oneof invoice_ref {
166
+ bytes payment_hash = 1;
167
+ bytes payment_addr = 2;
168
+ bytes set_id = 3;
169
+ }
170
+
171
+ LookupModifier lookup_modifier = 4;
137
172
  }
@@ -3056,6 +3056,10 @@ message HopHint {
3056
3056
  uint32 cltv_expiry_delta = 5;
3057
3057
  }
3058
3058
 
3059
+ message SetID {
3060
+ bytes set_id = 1;
3061
+ }
3062
+
3059
3063
  message RouteHint {
3060
3064
  /*
3061
3065
  A list of hop hints that when chained together can assist in reaching a
@@ -3064,6 +3068,20 @@ message RouteHint {
3064
3068
  repeated HopHint hop_hints = 1;
3065
3069
  }
3066
3070
 
3071
+ message AMPInvoiceState {
3072
+ // The state the HTLCs associated with this setID are in.
3073
+ InvoiceHTLCState state = 1;
3074
+
3075
+ // The settle index of this HTLC set, if the invoice state is settled.
3076
+ uint64 settle_index = 2;
3077
+
3078
+ // The time this HTLC set was settled expressed in unix epoch.
3079
+ int64 settle_time = 3;
3080
+
3081
+ // The total amount paid for the sub-invoice expressed in milli satoshis.
3082
+ int64 amt_paid_msat = 5;
3083
+ }
3084
+
3067
3085
  message Invoice {
3068
3086
  /*
3069
3087
  An optional memo to attach along with the invoice. Used for record keeping
@@ -3209,7 +3227,7 @@ message Invoice {
3209
3227
 
3210
3228
  /*
3211
3229
  The payment address of this invoice. This value will be used in MPP
3212
- payments, and also for newer invoies that always require the MPP paylaod
3230
+ payments, and also for newer invoices that always require the MPP payload
3213
3231
  for added end-to-end security.
3214
3232
  */
3215
3233
  bytes payment_addr = 26;
@@ -3218,6 +3236,16 @@ message Invoice {
3218
3236
  Signals whether or not this is an AMP invoice.
3219
3237
  */
3220
3238
  bool is_amp = 27;
3239
+
3240
+ /*
3241
+ [EXPERIMENTAL]:
3242
+
3243
+ Maps a 32-byte hex-encoded set ID to the sub-invoice AMP state for the
3244
+ given set ID. This field is always populated for AMP invoices, and can be
3245
+ used along side LookupInvoice to obtain the HTLC information related to a
3246
+ given sub-invoice.
3247
+ */
3248
+ map<string, AMPInvoiceState> amp_invoice_state = 28;
3221
3249
  }
3222
3250
 
3223
3251
  enum InvoiceHTLCState {
@@ -74,14 +74,14 @@ message KeyLocator {
74
74
 
75
75
  message KeyDescriptor {
76
76
  /*
77
- The raw bytes of the key being identified. Either this or the KeyLocator
78
- must be specified.
77
+ The raw bytes of the public key in the key pair being identified. Either
78
+ this or the KeyLocator must be specified.
79
79
  */
80
80
  bytes raw_key_bytes = 1;
81
81
 
82
82
  /*
83
- The key locator that identifies which key to use for signing. Either this
84
- or the raw bytes of the target key must be specified.
83
+ The key locator that identifies which private key to use for signing.
84
+ Either this or the raw bytes of the target public key must be specified.
85
85
  */
86
86
  KeyLocator key_loc = 2;
87
87
  }
package/package.json CHANGED
@@ -56,5 +56,5 @@
56
56
  "directory": "test/typescript"
57
57
  },
58
58
  "types": "index.d.ts",
59
- "version": "4.13.0"
59
+ "version": "4.13.1"
60
60
  }
@@ -4,7 +4,7 @@
4
4
  ["lightning", 1218],
5
5
  ["lightning", 1226],
6
6
  ["lightning", 1233],
7
- ["lightning", 3431],
7
+ ["lightning", 3459],
8
8
  ["router", 100],
9
9
  ["walletkit", 3],
10
10
  ["walletunlocker", 2]