mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-22 00:24:19 +01:00
After some discussion with @shesek, and my own usage, we agreed that a more comprehensive interface, which explicitly supports grouping, is desirable. Thus keys are now arrays, with the semantic that a key is either a parent or has a value, never both. For convenience in the JSON schema, we always return them as arrays, though we accept simple strings as arguments. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
49 lines
1.3 KiB
Markdown
49 lines
1.3 KiB
Markdown
lightning-listdatastore -- Command for listing (plugin) data
|
|
============================================================
|
|
|
|
SYNOPSIS
|
|
--------
|
|
|
|
**listdatastore** [*key*]
|
|
|
|
DESCRIPTION
|
|
-----------
|
|
|
|
The **listdatastore** RPC command allows plugins to fetch data which was
|
|
stored in the c-lightning database.
|
|
|
|
All immediate children of the *key* (or root children) are returned:
|
|
a *key* with children won't have a *hex* or *generation* entry.
|
|
|
|
RETURN VALUE
|
|
------------
|
|
|
|
[comment]: # (GENERATE-FROM-SCHEMA-START)
|
|
On success, an object containing **datastore** is returned. It is an array of objects, where each object contains:
|
|
- **key** (array of strings):
|
|
- 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
|
|
[comment]: # (GENERATE-FROM-SCHEMA-END)
|
|
|
|
The following error codes may occur:
|
|
- -32602: invalid parameters.
|
|
|
|
AUTHOR
|
|
------
|
|
|
|
Rusty Russell <<rusty@rustcorp.com.au>> is mainly responsible.
|
|
|
|
SEE ALSO
|
|
--------
|
|
|
|
lightning-datastore(7), lightning-deldatastore(7)
|
|
|
|
RESOURCES
|
|
---------
|
|
|
|
Main web site: <https://github.com/ElementsProject/lightning>
|
|
|
|
[comment]: # ( SHA256STAMP:ee29b53cad20c6dfe9e19a979816280cc9f778507e5638d1803418284125e4c1)
|