lightning 7.0.3 → 7.0.5
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
|
@@ -8,6 +8,8 @@ Methods for working with the Lightning Network
|
|
|
8
8
|
|
|
9
9
|
- [bitpay.com crypto-rpc](https://bitpay.com/) -
|
|
10
10
|
https://github.com/bitpay/crypto-rpc
|
|
11
|
+
- [channel.ninja](https://channel.ninja/) -
|
|
12
|
+
https://github.com/channelninja/channel.ninja
|
|
11
13
|
- [coinos.io](https://coinos.io/) - https://github.com/coinos/coinos-server
|
|
12
14
|
- [Galoy](https://galoy.io/) - https://github.com/GaloyMoney/galoy
|
|
13
15
|
- [Lightning Poker](https://lightning-poker.com/) -
|
|
@@ -18,8 +20,8 @@ Methods for working with the Lightning Network
|
|
|
18
20
|
https://github.com/ibz/lightning-shell
|
|
19
21
|
- [LNMarkets](https://twitter.com/lnmarkets) -
|
|
20
22
|
https://github.com/lnmarkets/umbrel
|
|
21
|
-
- [LNPingBot](https://github.com/swissrouting/lnpingbot) -
|
|
22
|
-
|
|
23
|
+
- [LNPingBot](https://github.com/swissrouting/lnpingbot) -
|
|
24
|
+
https://github.com/swissrouting/lnpingbot
|
|
23
25
|
- [p2plnbot](https://telegram.me/lnp2pbot) - https://github.com/grunch/p2plnbot
|
|
24
26
|
- [rekr](https://rekr.app/) - https://github.com/ryan-lingle/rekr
|
|
25
27
|
- [stackernews](https://stacker.news/) -
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import {
|
|
2
|
+
AuthenticatedLightningArgs,
|
|
3
|
+
AuthenticatedLightningMethod,
|
|
4
|
+
} from '../../typescript';
|
|
5
|
+
|
|
6
|
+
export type GetChainAddressesArgs = AuthenticatedLightningArgs;
|
|
7
|
+
|
|
8
|
+
export type GetChainAddressesResult = {
|
|
9
|
+
addresses: {
|
|
10
|
+
/** Chain Address String */
|
|
11
|
+
address: string;
|
|
12
|
+
/** Is Internal Change Address Bool */
|
|
13
|
+
is_change: boolean;
|
|
14
|
+
/** Balance of Funds Controlled by Output Script Tokens Number */
|
|
15
|
+
tokens: number;
|
|
16
|
+
}[];
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Get the wallet chain addresses
|
|
21
|
+
*
|
|
22
|
+
* Requires `onchain:read` permission
|
|
23
|
+
*
|
|
24
|
+
* This method is not supported on LND 0.15.5 and below
|
|
25
|
+
*/
|
|
26
|
+
export const getChainAddresses: AuthenticatedLightningMethod<
|
|
27
|
+
GetChainAddressesArgs,
|
|
28
|
+
GetChainAddressesResult
|
|
29
|
+
>;
|
|
@@ -4,6 +4,7 @@ export * from './close_channel';
|
|
|
4
4
|
export * from './fund_pending_channels';
|
|
5
5
|
export * from './fund_psbt';
|
|
6
6
|
export * from './get_block';
|
|
7
|
+
export * from './get_chain_addresses';
|
|
7
8
|
export * from './get_chain_balance';
|
|
8
9
|
export * from './get_chain_fee_estimate';
|
|
9
10
|
export * from './get_chain_fee_rate';
|
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.7",
|
|
11
11
|
"@grpc/proto-loader": "0.7.4",
|
|
12
|
-
"@types/express": "4.17.
|
|
13
|
-
"@types/node": "18.11.
|
|
12
|
+
"@types/express": "4.17.17",
|
|
13
|
+
"@types/node": "18.11.19",
|
|
14
14
|
"@types/request": "2.48.8",
|
|
15
15
|
"@types/ws": "8.5.4",
|
|
16
16
|
"async": "3.2.4",
|
|
@@ -26,15 +26,15 @@
|
|
|
26
26
|
"invoices": "2.2.3",
|
|
27
27
|
"psbt": "2.7.2",
|
|
28
28
|
"tiny-secp256k1": "2.2.1",
|
|
29
|
-
"type-fest": "3.5.
|
|
29
|
+
"type-fest": "3.5.5"
|
|
30
30
|
},
|
|
31
31
|
"description": "Lightning Network client library",
|
|
32
32
|
"devDependencies": {
|
|
33
33
|
"@alexbosworth/node-fetch": "2.6.2",
|
|
34
34
|
"@alexbosworth/tap": "15.0.12",
|
|
35
35
|
"tsd": "0.25.0",
|
|
36
|
-
"typescript": "4.9.
|
|
37
|
-
"ws": "8.
|
|
36
|
+
"typescript": "4.9.5",
|
|
37
|
+
"ws": "8.12.0"
|
|
38
38
|
},
|
|
39
39
|
"engines": {
|
|
40
40
|
"node": ">=14"
|
|
@@ -59,5 +59,5 @@
|
|
|
59
59
|
"directory": "test/typescript"
|
|
60
60
|
},
|
|
61
61
|
"types": "index.d.ts",
|
|
62
|
-
"version": "7.0.
|
|
62
|
+
"version": "7.0.5"
|
|
63
63
|
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import {expectError, expectType} from 'tsd';
|
|
2
|
+
import {AuthenticatedLnd} from '../../lnd_grpc';
|
|
3
|
+
import {getChainAddresses, GetChainAddressesResult} from '../../lnd_methods';
|
|
4
|
+
|
|
5
|
+
const lnd = {} as AuthenticatedLnd;
|
|
6
|
+
|
|
7
|
+
expectError(getChainAddresses());
|
|
8
|
+
expectError(getChainAddresses({}));
|
|
9
|
+
|
|
10
|
+
expectType<GetChainAddressesResult>(await getChainAddresses({lnd}));
|
|
11
|
+
|
|
12
|
+
expectType<void>(
|
|
13
|
+
getChainAddresses({lnd}, (error, result) => {
|
|
14
|
+
expectType<GetChainAddressesResult>(result);
|
|
15
|
+
}),
|
|
16
|
+
);
|