GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
LIGHTNING-LISTDATASTORE(7) LIGHTNING-LISTDATASTORE(7)

lightning-listdatastore -- Command for listing (plugin) data

listdatastore [key]

The listdatastore RPC command allows plugins to fetch data which was stored in the Core Lightning database.

key (one of, optional):
  • (array of strings): All immediate children of the key (or root children) are returned. Using the first element of the key as the plugin name (e.g. [ 'summary' ]) is recommended. An array of values to form a hierarchy (though a single value is treated as a one-element array).

  • (string, optional)

  • (string)

On success, an object containing datastore is returned. It is an array of objects, where each object contains:

key (array of strings):
(string, optional): Part of the key added to the datastore.

  • generation (u64, optional): The number of times this has been updated.

  • hex (hex, optional): The hex data from the datastore.

  • string (string, optional): The data as a string, if it's valid utf-8.

The following error codes may occur:

-32602: invalid parameters.

Rusty Russell <rusty@rustcorp.com.au> is mainly responsible.

lightning-datastore(7), lightning-deldatastore(7), lightning-datastoreusage(7)

Main web site: https://github.com/ElementsProject/lightning

Example 1:

Request:

$ lightning-cli listdatastore -k "key"='["employee"]'

{

"id": "example:listdatastore#1",
"method": "listdatastore",
"params": {
"key": [
"employee"
]
} }

Response:

{

"datastore": [
{
"key": [
"employee",
"index"
],
"generation": 0,
"hex": "736176696e6720656d706c6f796565206b65797320746f207468652073746f7265",
"string": "saving employee keys to the store"
}
] }

Example 2:

Request:

$ lightning-cli listdatastore -k "key"="somekey"

{

"id": "example:listdatastore#2",
"method": "listdatastore",
"params": {
"key": "somekey"
} }

Response:

{

"datastore": [
{
"key": [
"somekey"
],
"generation": 0,
"hex": "61",
"string": "a"
}
] }
Core Lightning v25.02.2

Search for    or go to Top of page |  Section 7 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.