From e736c4d5f403032e3a668391020af7db0cdfe0a1 Mon Sep 17 00:00:00 2001 From: Michael Schmoock Date: Tue, 7 Feb 2023 10:35:44 +0100 Subject: [PATCH] doc: listpeers new attribute num_channels --- doc/lightning-listpeers.7.md | 3 ++- doc/lightning-sql.7.md | 3 ++- doc/schemas/listpeers.schema.json | 9 ++++++++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/doc/lightning-listpeers.7.md b/doc/lightning-listpeers.7.md index 0d4ac5876..58ae047ce 100644 --- a/doc/lightning-listpeers.7.md +++ b/doc/lightning-listpeers.7.md @@ -43,6 +43,7 @@ On success, an object containing **peers** is returned. It is an array of objec - **id** (pubkey): the public key of the peer - **connected** (boolean): True if the peer is currently connected +- **num\_channels** (u32): The number of channels the peer has with this node *(added v23.02)* - **log** (array of objects, optional): if *level* is specified, logs for this peer: - **type** (string) (one of "SKIPPED", "BROKEN", "UNUSUAL", "INFO", "DEBUG", "IO\_IN", "IO\_OUT") @@ -399,4 +400,4 @@ Main web site: Lightning RFC site (BOLT \#9): -[comment]: # ( SHA256STAMP:b89450ac6f27e051003bcf0a382b51e117e2832729e9d80b0015d9cebfacfa2c) +[comment]: # ( SHA256STAMP:227b5af94d1f299a4e88e450c074960ca8d109b634e24693ad389ef02f64f525) diff --git a/doc/lightning-sql.7.md b/doc/lightning-sql.7.md index 5a0b50350..1fd2808bc 100644 --- a/doc/lightning-sql.7.md +++ b/doc/lightning-sql.7.md @@ -299,6 +299,7 @@ The following tables are currently supported: - `peers` indexed by `id` (see lightning-listpeers(7)) - `id` (type `pubkey`, sqltype `BLOB`) - `connected` (type `boolean`, sqltype `INTEGER`) + - `num_channels` (type `u32`, sqltype `INTEGER`) - related table `peers_netaddr` - `row` (reference to `peers.rowid`, sqltype `INTEGER`) - `arrindex` (index within array, sqltype `INTEGER`) @@ -471,4 +472,4 @@ RESOURCES --------- Main web site: -[comment]: # ( SHA256STAMP:dbb9286cf31dc82b33143d5274b1c4eecc75c5ba1dfc18bdf21b4baab585bd45) +[comment]: # ( SHA256STAMP:d25af4b0655ebd31db68932c5ea6b532bd134477e42df5d0c7428e4a03fd0335) diff --git a/doc/schemas/listpeers.schema.json b/doc/schemas/listpeers.schema.json index 6358994ed..1374eed62 100644 --- a/doc/schemas/listpeers.schema.json +++ b/doc/schemas/listpeers.schema.json @@ -13,7 +13,8 @@ "additionalProperties": true, "required": [ "id", - "connected" + "connected", + "num_channels" ], "properties": { "id": { @@ -24,6 +25,11 @@ "type": "boolean", "description": "True if the peer is currently connected" }, + "num_channels": { + "type": "u32", + "description": "The number of channels the peer has with this node", + "added": "v23.02" + }, "log": { "type": "array", "description": "if *level* is specified, logs for this peer", @@ -1091,6 +1097,7 @@ "id": {}, "channels": {}, "connected": {}, + "num_channels": {}, "htlcs": {}, "log": {}, "netaddr": {