core-lightning/doc/schemas/lightning-commando-listrunes.json
ShahanaFarooqui 35101c072a commando: update removal version for rpcs
We documented them as deprecated in v23.08 but unintentionally didn't deprecate them in the code. Thus we are starting their actual deprecation cycle from v24.08 release.

Updating removal version for commands `commando-rune`, `commando-listrunes`, and `commando-blacklist`

Changelog-None.
2024-06-18 14:06:06 +09:30

298 lines
9.2 KiB
JSON

{
"$schema": "../rpc-schema-draft.json",
"type": "object",
"additionalProperties": false,
"added": "v23.05",
"deprecated": [
"v23.08",
"v25.02"
],
"rpc": "commando-listrunes",
"title": "Command to list previously generated runes",
"description": [
"The **commando-listrunes** RPC command either lists runes that we stored as we generate them (see lightning-commando-rune(7)) or decodes the rune given on the command line.",
"",
"NOTE: Runes generated prior to v23.05 were not stored, so will not appear in this list."
],
"request": {
"required": [],
"properties": {
"rune": {
"type": "string",
"description": [
"Optional rune to list."
]
}
}
},
"response": {
"required": [
"runes"
],
"properties": {
"runes": {
"type": "array",
"items": {
"type": "object",
"additionalProperties": false,
"required": [
"rune",
"unique_id",
"restrictions",
"restrictions_as_english"
],
"properties": {
"rune": {
"type": "string",
"description": [
"Base64 encoded rune."
]
},
"unique_id": {
"type": "string",
"description": [
"Unique id assigned when the rune was generated; this is always a u64 for commando runes."
]
},
"restrictions": {
"type": "array",
"description": [
"The restrictions on what commands this rune can authorize."
],
"items": {
"type": "object",
"additionalProperties": false,
"required": [
"alternatives",
"english"
],
"properties": {
"alternatives": {
"type": "array",
"items": {
"type": "object",
"additionalProperties": false,
"required": [
"fieldname",
"value",
"condition",
"english"
],
"properties": {
"fieldname": {
"type": "string",
"description": [
"The field this restriction applies to; see commando-rune(7)."
]
},
"value": {
"type": "string",
"description": [
"The value accepted for this field."
]
},
"condition": {
"type": "string",
"description": [
"The way to compare fieldname and value."
]
},
"english": {
"type": "string",
"description": [
"English readable description of this alternative."
]
}
}
}
},
"english": {
"type": "string",
"description": [
"English readable summary of alternatives above."
]
}
}
}
},
"restrictions_as_english": {
"type": "string",
"description": [
"English readable description of the restrictions array above."
]
},
"stored": {
"type": "boolean",
"enum": [
false
],
"description": [
"This is false if the rune does not appear in our datastore (only possible when `rune` is specified)."
]
},
"blacklisted": {
"type": "boolean",
"enum": [
true
],
"description": [
"The rune has been blacklisted; see commando-blacklist(7)."
]
},
"last_used": {
"type": "number",
"description": [
"The last time this rune was successfully used."
],
"added": "23.11"
},
"our_rune": {
"type": "boolean",
"enum": [
false
],
"description": [
"This is not a rune for this node (only possible when `rune` is specified)."
]
}
}
}
}
}
},
"json_example": [
{
"request": {
"id": "example:commando-listrunes#1",
"method": "commando-listrunes",
"params": "{}"
},
"response": {
"runes": [
{
"rune": "OSqc7ixY6F-gjcigBfxtzKUI54uzgFSA6YfBQoWGDV89MA==",
"unique_id": "0",
"restrictions": [],
"restrictions_as_english": ""
},
{
"rune": "Am3W_wI0PRn4qVNEsJ2iInHyFPQK8wfdqEXztm8-icQ9MA==",
"stored": false,
"our_rune": false,
"unique_id": "1",
"restrictions": [],
"restrictions_as_english": ""
}
]
}
},
{
"request": {
"id": "example:commando-listrunes#2",
"method": "commando-listrunes",
"params": {
"rune": "Am3W_wI0PRn4qVNEsJ2iInHyFPQK8wfdqEXztm8-icQ9MA=="
}
},
"response": {
"runes": [
{
"rune": "Am3W_wI0PRn4qVNEsJ2iInHyFPQK8wfdqEXztm8-icQ9MA==",
"stored": false,
"our_rune": false,
"unique_id": "1",
"restrictions": [],
"restrictions_as_english": ""
}
]
}
},
{
"request": {
"id": "example:commando-listrunes#3",
"method": "commando-listrunes",
"params": {
"rune": "m_tyR0qqHUuLEbFJW6AhmBg-9npxVX2yKocQBFi9cvY9MyZpZF4wMjJkMjIzNjIwYTM1OWE0N2ZmNyZtZXRob2Q9bGlzdHBlZXJzJnBuYW1lbGV2ZWwhfHBuYW1lbGV2ZWwvaW8mcGFycjEhfHBhcnIxL2lv"
}
},
"response": {
"runes": [
{
"rune": "m_tyR0qqHUuLEbFJW6AhmBg-9npxVX2yKocQBFi9cvY9MyZpZF4wMjJkMjIzNjIwYTM1OWE0N2ZmNyZtZXRob2Q9bGlzdHBlZXJzJnBuYW1lbGV2ZWwhfHBuYW1lbGV2ZWwvaW8mcGFycjEhfHBhcnIxL2lv",
"stored": false,
"unique_id": "3",
"restrictions": [
{
"alternatives": [
{
"fieldname": "id",
"value": "022d223620a359a47ff7",
"condition": "^",
"english": "id starts with 022d223620a359a47ff7"
}
],
"english": "id starts with 022d223620a359a47ff7"
},
{
"alternatives": [
{
"fieldname": "method",
"value": "listpeers",
"condition": "=",
"english": "method equal to listpeers"
}
],
"english": "method equal to listpeers"
},
{
"alternatives": [
{
"fieldname": "pnamelevel",
"value": "",
"condition": "!",
"english": "pnamelevel is missing"
},
{
"fieldname": "pnamelevel",
"value": "io",
"condition": "/",
"english": "pnamelevel unequal to io"
}
],
"english": "pnamelevel is missing OR pnamelevel unequal to io"
},
{
"alternatives": [
{
"fieldname": "parr1",
"value": "",
"condition": "!",
"english": "parr1 is missing"
},
{
"fieldname": "parr1",
"value": "io",
"condition": "/",
"english": "parr1 unequal to io"
}
],
"english": "parr1 is missing OR parr1 unequal to io"
}
],
"restrictions_as_english": "id starts with 022d223620a359a47ff7 AND method equal to listpeers AND pnamelevel is missing OR pnamelevel unequal to io AND parr1 is missing OR parr1 unequal to io"
}
]
}
}
],
"author": [
"Shahana Farooqui <<sfarooqui@blockstream.com>> is mainly responsible."
],
"see_also": [
"lightning-commando-rune(7)",
"lightning-commando-blacklist(7)"
],
"resources": [
"Main web site: <https://github.com/ElementsProject/lightning>"
]
}