LIGHTNING-SPLICE_SIGNED(7)
Okay bestie, welcome to the LIGHTNING-SPLICE_SIGNED(7) page β the manual for splice_signed, and itβs giving final-boss-of-splicing energy. β¨π
πΈ NAME πΈ
splice_signed β the command to initiate a channel to a peer. Thatβs the whole name vibe, periodt. π
β¨ SYNOPSIS β¨
splice_signed channel_id psbt [sign_first]
π DESCRIPTION π
Okay so this command was added in v23.08. splice_signed is a low level RPC command which finishes the active channel splice associated with channel_id β like the final βyes bestie, lock it inβ step. π«Ά
The psbt must have all signatures attached to all inputs that you have added to it or it will fail. No cap: missing sigs = no slay. π
The args are:
channel_id(hash) β the channel id of the channel to be spliced.psbt(string) β the psbt of the resulting transaction after splice negotiation(s).sign_first(boolean, optional) β a flag that makes our node offer the final splice signature first (defaults tofalse). Whenfalse, the node will calculate who should sign first based off who is adding inputting the least sats to the splice as per spec.
π RETURN VALUE π
On success, an object is returned, containing:
tx(hex) β the hex representation of the final transaction that is published.txid(txid) β the txid is of the final transaction.psbt(string) β the psbt of the resulting transaction after splice negotiation(s).outnum(u32, optional) β the index of the new funding output. (added v24.08)
π¦ AUTHOR π¦
Dusty @dusty_daemon is mainly responsible. iconic. π«Ά
π SEE ALSO π
lightning-splice_init(7), lightning-splice_update(7)
π RESOURCES π
Main web site: https://github.com/ElementsProject/lightning
π οΈ USAGE π οΈ
In this example we funded the psbt from our lightning node, so we can use the lightning node to sign for its funds. π
SIGNPSBT=$(echo $(lightning-cli signpsbt $PSBT_SPLICE_UPDATE) | jq -r ".signed_psbt")
$ lightning-cli splice_signed $CHANNEL_ID $SIGNPSBT
Here is an example set of splice commands that will splice in 100,000 sats to the first channel that comes out of listpeerchannels.
The example assumes you already have at least one confirmed channel.
1: Get the channel id of the first channel.
CHANNEL_ID=$(echo $(lightning-cli listpeerchannels) | jq -r ".channels[0].channel_id")
2: Get the PSBT from fundpsbt.
INITIALPSBT=$(echo $(lightning-cli fundpsbt -k satoshi=100000sat feerate=urgent startweight=800 excess_as_change=true) | jq -r ".psbt")
3: Initiate the splice by passing channel id and initialpsbt received from above steps.
PSBT_SPLICE_INIT=$(echo $(lightning-cli splice_init $CHANNEL_ID 100000 $INITIALPSBT) | jq -r ".psbt")
4: Update PSBTs with the splice_update command.
RESULT={"commitments_secured":false}
while [[ $(echo $RESULT | jq -r ".commitments_secured") == "false" ]]
do
PSBT_SPLICE_UPDATE=$(echo $(lightning-cli splice_update $CHANNEL_ID $PSBT_SPLICE_INIT) | jq -r ".psbt")
echo $PSBT_SPLICE_UPDATE
done
5: Sign the updated PSBT.
SIGNPSBT=$(echo $(lightning-cli signpsbt -k psbt="$PSBT_SPLICE_UPDATE") | jq -r ".signed_psbt")
6: Finally, call splice_signed with channel id and signed PSBT parameters.
$ lightning-cli splice_signed $CHANNEL_ID $SIGNPSBT
π EXAMPLES π
Example 1:
Request:
$ lightning-cli splice_signed -k "channel_id"="channelid0780000780000780000780000780000780000780000780000780000" "psbt"="cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000"
{
"id": "example:splice_signed#1",
"method": "splice_signed",
"params": {
"channel_id": "channelid0780000780000780000780000780000780000780000780000780000",
"psbt": "cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000718000"
}
}
Response:
{
"tx": "02000000000101sendpt64000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000640006400064000",
"txid": "txid6400064000640006400064000640006400064000640006400064000",
"outnum": 1,
"psbt": "cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000711000"
}
Example 2:
Request:
$ lightning-cli splice_signed -k "channel_id"="channelid0780000780000780000780000780000780000780000780000780000" "psbt"="cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000"
{
"id": "example:splice_signed#2",
"method": "splice_signed",
"params": {
"channel_id": "channelid0780000780000780000780000780000780000780000780000780000",
"psbt": "cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000"
}
}
Response:
{
"tx": "02000000000102sendpt65000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000650006500065000",
"txid": "txid6500065000650006500065000650006500065000650006500065000",
"outnum": 1,
"psbt": "cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000712000"
}
Thatβs the footer vibe, bestie: Core Lightning v26.06.9 + LIGHTNING-SPLICE_SIGNED(7). Mwah! π
π¦ where this page comes from
- nixpkgs unstable: clightning 26.06.9
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms