lightning 9.8.2 → 9.9.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
package/README.md
CHANGED
|
@@ -22,6 +22,8 @@ Methods for working with the Lightning Network
|
|
|
22
22
|
https://github.com/lnmarkets/umbrel
|
|
23
23
|
- [LNPingBot](https://github.com/swissrouting/lnpingbot) -
|
|
24
24
|
https://github.com/swissrouting/lnpingbot
|
|
25
|
+
- [MutinyWallet faucet](https://github.com/MutinyWallet/mutinynet-faucet) -
|
|
26
|
+
https://www.mutinywallet.com/
|
|
25
27
|
- [p2plnbot](https://telegram.me/lnp2pbot) - https://github.com/grunch/p2plnbot
|
|
26
28
|
- [rekr](https://rekr.app/) - https://github.com/ryan-lingle/rekr
|
|
27
29
|
- [stackernews](https://stacker.news/) -
|
|
@@ -18,6 +18,8 @@ export type ChannelOpenOptions = {
|
|
|
18
18
|
give_tokens?: number;
|
|
19
19
|
/** Channel is Private */
|
|
20
20
|
is_private?: boolean;
|
|
21
|
+
/** Peer Should Avoid Waiting For Confirmation */
|
|
22
|
+
is_trusted_funding?: boolean;
|
|
21
23
|
/** Local Tokens */
|
|
22
24
|
local_tokens: number;
|
|
23
25
|
/** Spend UTXOs With Minimum Confirmations */
|
|
@@ -4,6 +4,7 @@ const {returnResult} = require('asyncjs-util');
|
|
|
4
4
|
const {addPeer} = require('./../peers');
|
|
5
5
|
const {isLnd} = require('./../../lnd_requests');
|
|
6
6
|
|
|
7
|
+
const anchors = 'ANCHORS';
|
|
7
8
|
const defaultMinConfs = 1;
|
|
8
9
|
const defaultMinHtlcMtokens = '1';
|
|
9
10
|
const errMemoLength = /^provided memo \(.*\) is of length \d*, exceeds (\d*)$/;
|
|
@@ -11,6 +12,7 @@ const minChannelTokens = 20000;
|
|
|
11
12
|
const method = 'openChannel';
|
|
12
13
|
const type = 'default';
|
|
13
14
|
|
|
15
|
+
|
|
14
16
|
/** Open a new channel.
|
|
15
17
|
|
|
16
18
|
The capacity of the channel is set with local_tokens
|
|
@@ -28,6 +30,10 @@ const type = 'default';
|
|
|
28
30
|
|
|
29
31
|
`description` is not supported on LND 0.16.4 and below
|
|
30
32
|
|
|
33
|
+
`is_trusted_funding` is not supported on LND 0.15.0 and below and requires
|
|
34
|
+
`--protocol.option-scid-alias` and `--protocol.zero-conf` set on both sides
|
|
35
|
+
as well as a channel open request listener to accept the trusted funding.
|
|
36
|
+
|
|
31
37
|
{
|
|
32
38
|
[base_fee_mtokens]: <Routing Base Fee Millitokens Charged String>
|
|
33
39
|
[chain_fee_tokens_per_vbyte]: <Chain Fee Tokens Per VByte Number>
|
|
@@ -37,6 +43,7 @@ const type = 'default';
|
|
|
37
43
|
[give_tokens]: <Tokens to Gift To Partner Number> // Defaults to zero
|
|
38
44
|
[is_max_funding]: <Use Maximal Chain Funds For Local Funding Bool>
|
|
39
45
|
[is_private]: <Channel is Private Bool> // Defaults to false
|
|
46
|
+
[is_trusted_funding]: <Accept Funding as Trusted Bool>
|
|
40
47
|
lnd: <Authenticated LND API Object>
|
|
41
48
|
[local_tokens]: <Total Channel Capacity Tokens Number>
|
|
42
49
|
[min_confirmations]: <Spend UTXOs With Minimum Confirmations Number>
|
|
@@ -105,6 +112,7 @@ module.exports = (args, cbk) => {
|
|
|
105
112
|
|
|
106
113
|
const options = {
|
|
107
114
|
base_fee: args.base_fee_mtokens || undefined,
|
|
115
|
+
commitment_type: args.is_trusted_funding ? anchors : undefined,
|
|
108
116
|
fee_rate: args.fee_rate,
|
|
109
117
|
fund_max: args.is_max_funding || undefined,
|
|
110
118
|
local_funding_amount: args.local_tokens,
|
|
@@ -117,6 +125,7 @@ module.exports = (args, cbk) => {
|
|
|
117
125
|
spend_unconfirmed: !minConfs,
|
|
118
126
|
use_base_fee: args.base_fee_mtokens !== undefined,
|
|
119
127
|
use_fee_rate: args.fee_rate !== undefined,
|
|
128
|
+
zero_conf: !!args.is_trusted_funding || undefined,
|
|
120
129
|
};
|
|
121
130
|
|
|
122
131
|
if (!!args.chain_fee_tokens_per_vbyte) {
|
package/package.json
CHANGED
|
@@ -7,10 +7,10 @@
|
|
|
7
7
|
"url": "https://github.com/alexbosworth/lightning/issues"
|
|
8
8
|
},
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@grpc/grpc-js": "1.8.
|
|
10
|
+
"@grpc/grpc-js": "1.8.19",
|
|
11
11
|
"@grpc/proto-loader": "0.7.8",
|
|
12
12
|
"@types/express": "4.17.17",
|
|
13
|
-
"@types/node": "20.4.
|
|
13
|
+
"@types/node": "20.4.4",
|
|
14
14
|
"@types/request": "2.48.8",
|
|
15
15
|
"@types/ws": "8.5.5",
|
|
16
16
|
"async": "3.2.4",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"body-parser": "1.20.2",
|
|
21
21
|
"bolt07": "1.8.4",
|
|
22
22
|
"bolt09": "1.0.0",
|
|
23
|
-
"cbor": "9.0.
|
|
23
|
+
"cbor": "9.0.1",
|
|
24
24
|
"ecpair": "2.1.0",
|
|
25
25
|
"express": "4.18.2",
|
|
26
26
|
"invoices": "3.0.0",
|
|
@@ -58,5 +58,5 @@
|
|
|
58
58
|
"directory": "test/typescript"
|
|
59
59
|
},
|
|
60
60
|
"types": "index.d.ts",
|
|
61
|
-
"version": "9.
|
|
61
|
+
"version": "9.9.1"
|
|
62
62
|
}
|