mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-11-19 18:11:28 +01:00
887c6f71cf
PSBTv2 support is quite low in the ecosystem, so having a call to convert log messages and the like should be useful since they'll often be in v2. Changelog-Added: Added setpsbtversion RPC to aid debugging and compatibility
1.2 KiB
1.2 KiB
lightning-setpsbtversion -- Command for setting PSBT version
SYNOPSIS
setpsbtversion psbt version
DESCRIPTION
The setpsbtversion RPC command converts the provided PSBT to the given version, and returns the base64 result of the conversion. Returns an error if version is invalid.
- psbt: The PSBT to change versions.
- version: The version to set.
EXAMPLE JSON REQUEST
{
"id": 82,
"method": "setpsbtversion",
"params": {
"psbt": "cHNidP8BAAoCAAAAAAAAAAAAAA==",
"version": "2"
}
}
RETURN VALUE
If successful the command returns a converted PSBT of the requested version.
On failure, an error is returned.
The following error codes may occur:
- -32602: Parameter missed or malformed;
EXAMPLE JSON RESPONSE
{
"psbt": "cHNidP8BAgQCAAAAAQQBAAEFAQABBgEDAfsEAgAAAAA="
}
AUTHOR
Gregory Sanders <gsanders87@gmail.com> is mainly responsible.
SEE ALSO
lightning-fundpsbt(7), lightning-utxopsbt(7), lightning-signpsbt(7).
RESOURCES
Main web site: https://github.com/ElementsProject/lightning