LIGHTNING-TXSEND(7)

πŸ“¦
version 26.06.9 Β· 2 versions
, in nixpkgs unstable

πŸ’Έ lightning-txsend(7) β€” the glow-up πŸ’Έ

okay bestie, so this is the manual page for LIGHTNING-TXSEND, and it's genuinely so simple you're gonna slay it. it's the "hit send on the thing you already prepped" command. main character energy fr fr.


✨ NAME ✨

txsend β€” the command that signs and sends a transaction that came out of txprepare. it's giving "you already did the hard part, now just press the button" 🫢


🌸 SYNOPSIS 🌸

txsend txid

πŸ¦‹ DESCRIPTION πŸ¦‹

the txsend RPC command signs and broadcasts a transaction that was created by the txprepare RPC command. that's it. that's the whole vibe. ✨

  • txid (txid) β€” the transaction id of the transaction that the txprepare rpc command made. you're literally just handing it the receipt from last time, no cap.

πŸŽ€ RETURN VALUE πŸŽ€

when it works (and it will, bestie), you get back an object containing:

  • psbt (string) β€” the completed PSBT representing the signed transaction. like the fully finished, signed-off version πŸ’…
  • tx (hex) β€” the fully signed transaction. the actual thing πŸ₯³
  • txid (txid) β€” the transaction id of tx. so you know which one it is πŸ’–

πŸ’€ ERRORS πŸ’€

if it flops, an error is reported (coming from bitcoind), and the inputs from the transaction are unreserved. like, they get released. noted. πŸ™ˆ

  • -1 β€” catchall nonspecific error. the "something went wrong, that's all we know" one. iconic in its vagueness honestly.

πŸ‘‘ AUTHOR πŸ‘‘

Rusty Russell rusty@rustcorp.com.au is mainly responsible. we stan a legend 🫢


🧚 SEE ALSO 🧚


🌈 RESOURCES 🌈

main web site: https://github.com/ElementsProject/lightning β€” go be nosy, iykyk πŸ’œ


⭐ EXAMPLES ⭐

example 1 πŸ“

request:

$ lightning-cli txsend "txidtxprep000200002000020000200002000020000200002000020000200002"
{
  "id": "example:txsend#1",
  "method": "txsend",
  "params": [
    "txidtxprep000200002000020000200002000020000200002000020000200002"
  ]
}

response:

{
  "tx": "02000000000101txsend00011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011000110001100011",
  "txid": "txidtxprep000200002000020000200002000020000200002000020000200002",
  "psbt": "cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100011100"
}

example 2 πŸ¦‹

request:

$ lightning-cli txsend -k "txid"="txidtxprep000400004000040000400004000040000400004000040000400004"
{
  "id": "example:txsend#2",
  "method": "txsend",
  "params": {
    "txid": "txidtxprep000400004000040000400004000040000400004000040000400004"
  }
}

response:

{
  "tx": "02000000000101txsend00022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022000220002200022",
  "txid": "txidtxprep000400004000040000400004000040000400004000040000400004",
  "psbt": "cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200022200"
}

and that's the whole page, bestie πŸ’– this was Core Lightning v26.06.9 β€” go sign something and be iconic. periodt. πŸ‘‘βœ¨

πŸ“¦ where this page comes from