ln-service 53.20.0 → 53.23.0

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,5 +1,17 @@
1
1
  # Versions
2
2
 
3
+ ## 53.23.0
4
+
5
+ - `getChainFeeEstimate`: Add support for specifying min `utxo_confirmations`
6
+
7
+ ## 53.22.0
8
+
9
+ - `parsePaymentRequest`: Add support for parsing payment request metadata
10
+
11
+ ## 53.21.0
12
+
13
+ - `getLockedUtxos`: Add support for locked UTXO `output_script`, `tokens`
14
+
3
15
  ## 53.20.0
4
16
 
5
17
  - `closeChannel`: Add support for `max_tokens_per_vbyte` to set max fee rate
package/README.md CHANGED
@@ -9,7 +9,7 @@ through npm.
9
9
 
10
10
  Supported LND versions:
11
11
 
12
- - v0.15.0-beta
12
+ - v0.15.0-beta to v0.15.1-beta
13
13
  - v0.14.0-beta to v0.14.3-beta
14
14
  - v0.13.0-beta to v0.13.4-beta
15
15
  - v0.12.0-beta to v0.12.1-beta
@@ -48,7 +48,7 @@ If you're going to use extended gRPC APIs, make sure to add the APIs to make
48
48
  tags.
49
49
 
50
50
  ```sh
51
- make && make install tags="autopilotrpc chainrpc invoicesrpc routerrpc signrpc walletrpc watchtowerrpc wtclientrpc"
51
+ make && make install tags="autopilotrpc chainrpc invoicesrpc peersrpc routerrpc signrpc walletrpc watchtowerrpc wtclientrpc"
52
52
  ```
53
53
 
54
54
  ## Using gRPC
@@ -1437,6 +1437,8 @@ Get a chain fee estimate for a prospective chain send
1437
1437
 
1438
1438
  Requires `onchain:read` permission
1439
1439
 
1440
+ Specifying 0 for `utxo_confirmations` is not supported in LND 0.13.0 or below
1441
+
1440
1442
  {
1441
1443
  lnd: <Authenticated LND API Object>
1442
1444
  send_to: [{
@@ -2253,6 +2255,8 @@ Requires LND built with `walletrpc` build tag
2253
2255
 
2254
2256
  This method is not supported on LND 0.12.1 and below
2255
2257
 
2258
+ `output_script`, `tokens` are not supported on LND 0.15.0 and below
2259
+
2256
2260
  {
2257
2261
  lnd: <Authenticated LND API Object>
2258
2262
  }
@@ -2262,6 +2266,8 @@ This method is not supported on LND 0.12.1 and below
2262
2266
  utxos: [{
2263
2267
  lock_expires_at: <Lock Expires At ISO 8601 Date String>
2264
2268
  lock_id: <Locking Id Hex String>
2269
+ [output_script]: <Outpoint Output Script Hex String>
2270
+ [tokens]: <Token Value of Outpoint Number>
2265
2271
  transaction_id: <Transaction Id Hex String>
2266
2272
  transaction_vout: <Transaction Output Index Number>
2267
2273
  }]
@@ -3691,6 +3697,7 @@ Note: either description or description_hash will be returned
3691
3697
  }]
3692
3698
  id: <Payment Request Hash String>
3693
3699
  is_expired: <Invoice is Expired Bool>
3700
+ [metadata]: <Payment Metadata Hex String>
3694
3701
  [mtokens]: <Requested Milli-Tokens Value String> (can exceed Number limit)
3695
3702
  network: <Network Name String>
3696
3703
  [payment]: <Payment Identifier Hex Encoded String>
@@ -5540,6 +5547,7 @@ LND 0.15.0 and below do not support `is_trusted_funding`
5540
5547
  {
5541
5548
  accept: <Accept Request Function> ({
5542
5549
  [cooperative_close_address]: <Restrict Coop Close To Address String>
5550
+ [is_trusted_funding]: <Accept Funding as Trusted Bool>
5543
5551
  [min_confirmations]: <Required Confirmations Before Channel Open Number>
5544
5552
  [remote_csv]: <Peer Unilateral Balance Output CSV Delay Number>
5545
5553
  [remote_reserve]: <Minimum Tokens Peer Must Keep On Their Side Number>
@@ -5553,6 +5561,7 @@ LND 0.15.0 and below do not support `is_trusted_funding`
5553
5561
  csv_delay: <CSV Delay Blocks Number>
5554
5562
  id: <Request Id Hex String>
5555
5563
  is_private: <Incoming Channel Is Private Bool>
5564
+ is_trusted_funding: <Request Immediate Trusted Funding Bool>
5556
5565
  local_balance: <Channel Local Tokens Balance Number>
5557
5566
  local_reserve: <Channel Local Reserve Tokens Number>
5558
5567
  max_pending_mtokens: <Maximum Millitokens Pending In Channel String>
package/package.json CHANGED
@@ -10,8 +10,8 @@
10
10
  "bolt07": "1.8.2",
11
11
  "cors": "2.8.5",
12
12
  "express": "4.18.1",
13
- "invoices": "2.1.0",
14
- "lightning": "5.19.0",
13
+ "invoices": "2.2.0",
14
+ "lightning": "5.21.0",
15
15
  "macaroon": "3.0.4",
16
16
  "morgan": "1.10.0",
17
17
  "ws": "8.8.1"
@@ -28,8 +28,8 @@
28
28
  "bn.js": "5.2.1",
29
29
  "bs58check": "2.1.2",
30
30
  "ecpair": "2.0.1",
31
- "ln-docker-daemons": "2.3.4",
32
- "p2tr": "1.3.1",
31
+ "ln-docker-daemons": "2.3.6",
32
+ "p2tr": "1.3.2",
33
33
  "portfinder": "1.0.32",
34
34
  "psbt": "2.7.1",
35
35
  "rimraf": "3.0.2",
@@ -56,6 +56,7 @@
56
56
  "url": "https://github.com/alexbosworth/ln-service.git"
57
57
  },
58
58
  "scripts": {
59
+ "integration-test-0.15.1": "DOCKER_LND_VERSION=v0.15.1-beta npm run test",
59
60
  "integration-test-0.15.0": "DOCKER_LND_VERSION=v0.15.0-beta npm run test",
60
61
  "integration-test-0.14.3": "DOCKER_LND_VERSION=v0.14.3-beta npm run test",
61
62
  "integration-test-0.14.2": "DOCKER_LND_VERSION=v0.14.2-beta npm run test",
@@ -70,5 +71,5 @@
70
71
  "integration-test-0.12.0": "DOCKER_LND_VERSION=v0.12.0-beta npm run test",
71
72
  "test": "echo $DOCKER_LND_VERSION && tap -j 2 --branches=1 --functions=1 --lines=1 --statements=1 -t 200 test/autopilotrpc-integration/*.js test/chainrpc-integration/*.js test/integration/*.js test/invoicesrpc-integration/*.js test/peersrpc-integration/*.js test/routerrpc-integration/*.js test/signerrpc-integration/*.js test/tower_clientrpc-integration/*.js test/tower_serverrpc-integration/*.js test/walletrpc-integration/*.js"
72
73
  },
73
- "version": "53.20.0"
74
+ "version": "53.23.0"
74
75
  }
@@ -43,6 +43,13 @@ test(`Lock UTXO`, async ({end, equal, rejects, strictSame}) => {
43
43
 
44
44
  const [locked] = (await getLockedUtxos({lnd})).utxos;
45
45
 
46
+ const got = {
47
+ lock_expires_at: locked.lock_expires_at,
48
+ lock_id: locked.lock_id,
49
+ transaction_id: locked.transaction_id,
50
+ transaction_vout: locked.transaction_vout,
51
+ };
52
+
46
53
  const expected = {
47
54
  lock_expires_at: lock.expires_at,
48
55
  lock_id: lock.id,
@@ -50,7 +57,14 @@ test(`Lock UTXO`, async ({end, equal, rejects, strictSame}) => {
50
57
  transaction_vout: utxo.transaction_vout,
51
58
  };
52
59
 
53
- strictSame(locked, expected, 'Got expected UTXO lock');
60
+ strictSame(got, expected, 'Got expected UTXO lock');
61
+
62
+ // LND 0.15.0 and below do not support locked UTXO output script
63
+ if (!!locked.output_script) {
64
+ equal(locked.output_script, utxo.output_script, 'Got output script');
65
+ equal(locked.tokens, utxo.tokens, 'Got output value');
66
+ }
67
+
54
68
  } catch (err) {
55
69
  strictSame(
56
70
  err,