LIGHTNING-UNRESERVEINPUTS(7)

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

πŸ’– LIGHTNING-UNRESERVEINPUTS(7) πŸ’–

okay bestie, welcome to your new favorite manual page: lightning-unreserveinputs, from the Core Lightning fam. it's literally the "release reserved UTXOs" moment and it ate, no cap ✨


🌸 NAME 🌸

unreserveinputs β€” release reserved UTXOs 🫢


πŸŽ€ SYNOPSIS πŸŽ€

unreserveinputs psbt [reserve]

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so the unreserveinputs RPC command releases (or lowkey just reduces the reservation) on UTXOs that were previously marked as reserved β€” and those were, like, generally marked by lightning-reserveinputs(7) in the first place. main character energy tbh πŸ’…

  • psbt (string): the inputs you want to unreserve are exactly the inputs specified in the passed-in psbt. that's the whole vibe check.
  • reserve (u32, optional): how many blocks to decrease the reservation by. the default is 72. yeah, 72. iconic default number fr fr.

✨ RETURN VALUE ✨

on success, you get an object containing reservations. it's an array of objects, and every single object contains:

  • txid (txid): the transaction id 🧚
  • vout (u32): the output number which was reserved
  • was_reserved (boolean): whether the input was already reserved (usually true)
  • reserved (boolean): whether the input is now reserved β€” and heads up, it may still be true if it was reserved for a long time πŸ‘‘

if reserved is true:

  • reserved_to_block (u32): what blockheight the reservation will expire. so you know exactly when it's over, like a situationship πŸ’€

πŸ™ˆ ERRORS πŸ™ˆ

on failure, an error is reported and no UTXOs are unreserved. nothing happens. zero. zilch. the reservation stays put, bestie 😭

  • -32602: invalid parameter, i.e. an unparseable PSBT.

🌈 AUTHOR 🌈

Lisa Neigut niftynei@gmail.com is mainly responsible. queen behavior, we stan πŸ‘‘πŸ«Ά


πŸ’œ SEE ALSO πŸ’œ

lightning-unreserveinputs(7), lightning-signpsbt(7), lightning-sendpsbt(7)


⭐ RESOURCES ⭐

main web site: https://github.com/ElementsProject/lightning


πŸ“ EXAMPLES πŸ“

Example 1 πŸŽ€

Request:

$ lightning-cli unreserveinputs -k "psbt"="cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000" "reserve"=200
{
  "id": "example:unreserveinputs#1",
  "method": "unreserveinputs",
  "params": {
    "psbt": "cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000310000",
    "reserve": 200
  }
}

Response:

{
  "reservations": []
}

Example 2 πŸ’€

Request:

$ lightning-cli unreserveinputs "cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000"
{
  "id": "example:unreserveinputs#2",
  "method": "unreserveinputs",
  "params": [
    "cHNidP8BAgQCAAAAAQMEbwAAAAEEAQpsbt410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000410000"
  ]
}

Response:

{
  "reservations": []
}

ngl, both examples return an empty reservations array, so don't come for me β€” that's literally what the page says πŸ™ˆ

and that's the whole page, bestie!! thanks for reading, this was Core Lightning v26.06.9, and the date line is LIGHTNING-UNRESERVEINPUTS(7) β€” slay, periodt πŸ’…βœ¨πŸŽ€πŸ¦‹πŸ’–

πŸ“¦ where this page comes from