mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-02-21 14:24:09 +01:00
122 lines
2.7 KiB
JSON
122 lines
2.7 KiB
JSON
{
|
|
"$schema": "../rpc-schema-draft.json",
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"rpc": "setchannel",
|
|
"title": "Command for configuring fees / htlc range advertized for a channel",
|
|
"description": [],
|
|
"request": {
|
|
"required": [],
|
|
"properties": {
|
|
"expired_by": {
|
|
"type": "u64",
|
|
"description": [
|
|
"How long an invoice must be expired (seconds) before we delete it."
|
|
]
|
|
},
|
|
"cycle_seconds": {
|
|
"type": "u64",
|
|
"description": [
|
|
"The interval (in seconds) between cleaning expired invoices."
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"response": {
|
|
"required": [
|
|
"enabled"
|
|
],
|
|
"properties": {
|
|
"enabled": {
|
|
"type": "boolean",
|
|
"description": [
|
|
"Whether invoice autocleaning is active."
|
|
]
|
|
}
|
|
},
|
|
"allOf": [
|
|
{
|
|
"if": {
|
|
"properties": {
|
|
"enabled": {
|
|
"type": "boolean",
|
|
"enum": [
|
|
true
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"then": {
|
|
"additionalProperties": false,
|
|
"required": [
|
|
"expired_by",
|
|
"cycle_seconds"
|
|
],
|
|
"properties": {
|
|
"enabled": {},
|
|
"expired_by": {
|
|
"type": "u64",
|
|
"description": [
|
|
"How long an invoice must be expired (seconds) before we delete it."
|
|
]
|
|
},
|
|
"cycle_seconds": {
|
|
"type": "u64",
|
|
"description": [
|
|
"How long an invoice must be expired (seconds) before we delete it."
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"else": {
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"enabled": {}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"json_example": [
|
|
{
|
|
"request": {
|
|
"id": "example:autocleaninvoice#1",
|
|
"method": "autocleaninvoice",
|
|
"params": {
|
|
"cycle_seconds": 8,
|
|
"expired_by": 2
|
|
}
|
|
},
|
|
"response": {
|
|
"enabled": true,
|
|
"cycle_seconds": 8,
|
|
"expired_by": 2
|
|
}
|
|
},
|
|
{
|
|
"request": {
|
|
"id": "example:autocleaninvoice#2",
|
|
"method": "autocleaninvoice",
|
|
"params": {
|
|
"cycle_seconds": 1,
|
|
"expired_by": 1
|
|
}
|
|
},
|
|
"response": {
|
|
"enabled": true,
|
|
"cycle_seconds": 1,
|
|
"expired_by": 1
|
|
}
|
|
}
|
|
],
|
|
"author": [
|
|
"Rusty Russell <<rusty@rustcorp.com.au>> is mainly responsible."
|
|
],
|
|
"see_also": [
|
|
"lightningd-config(5)",
|
|
"lightning-listinvoices(7)"
|
|
],
|
|
"resources": [
|
|
"Main web site: <https://github.com/ElementsProject/lightning>"
|
|
]
|
|
}
|