-
Notifications
You must be signed in to change notification settings - Fork 37.7k
doc: Fixup getrawtransaction RPC docs #26734
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. ReviewsSee the guideline for information on the review process.
If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update. |
Thanks, ACK 97115de |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cr utACK 97115de
Rendered diff: diff --git a/decoderawtransaction b/decoderawtransaction
index 05a49fe..7600def 100644
--- a/decoderawtransaction
+++ b/decoderawtransaction
@@ -45,8 +45,8 @@ Result:
"asm" : "str", (string) Disassembly of the public key script
"desc" : "str", (string) Inferred descriptor for the output
"hex" : "hex", (string) The raw public key script bytes, hex-encoded
- "type" : "str", (string) The type, eg 'pubkeyhash'
- "address" : "str" (string, optional) The Bitcoin address (only if a well-defined address exists)
+ "address" : "str", (string, optional) The Bitcoin address (only if a well-defined address exists)
+ "type" : "str" (string) The type (one of: nonstandard, pubkey, pubkeyhash, scripthash, multisig, nulldata, witness_v0_scripthash, witness_v0_keyhash, witness_v1_taproot, witness_unknown)
}
},
...
diff --git a/getrawtransaction b/getrawtransaction
index 462f051..6750205 100644
--- a/getrawtransaction
+++ b/getrawtransaction
@@ -8,8 +8,8 @@ the specified block is available and the transaction is in that block.
Hint: Use gettransaction for wallet transactions.
If verbosity is 0 or omitted, returns the serialized transaction as a hex-encoded string.
-If verbosity is 1, returns a JSON Object with information about transaction.
-If verbosity is 2, returns a JSON Object with information about transaction, including fee and prevout information.
+If verbosity is 1, returns a JSON Object with information about the transaction.
+If verbosity is 2, returns a JSON Object with information about the transaction, including fee and prevout information.
Arguments:
1. txid (string, required) The transaction id
@@ -59,8 +59,8 @@ Result (if verbosity is set to 1):
"asm" : "str", (string) Disassembly of the public key script
"desc" : "str", (string) Inferred descriptor for the output
"hex" : "hex", (string) The raw public key script bytes, hex-encoded
- "type" : "str", (string) The type, eg 'pubkeyhash'
- "address" : "str" (string, optional) The Bitcoin address (only if a well-defined address exists)
+ "address" : "str", (string, optional) The Bitcoin address (only if a well-defined address exists)
+ "type" : "str" (string) The type (one of: nonstandard, pubkey, pubkeyhash, scripthash, multisig, nulldata, witness_v0_scripthash, witness_v0_keyhash, witness_v1_taproot, witness_unknown)
}
},
...
@@ -72,9 +72,9 @@ Result (for verbosity = 2):
..., Same output as verbosity = 1
"fee" : n, (numeric, optional) transaction fee in BTC, omitted if block undo data is not available
"vin" : [ (json array)
- { (json object, optional) utxo being spent, omitted if block undo data is not available
+ { (json object) utxo being spent, omitted if block undo data is not available
..., Same output as verbosity = 1
- "prevout" : { (json object) Only if undo information is available)
+ "prevout" : { (json object, optional) Only if undo information is available)
"generated" : true|false, (boolean) Coinbase or not
"height" : n, (numeric) The height of the prevout
"value" : n, (numeric) The value in BTC |
{RPCResult::Type::ARR, "vin", "", | ||
{ | ||
{RPCResult::Type::OBJ, "", /* optional */ true, "utxo being spent, omitted if block undo data is not available", | ||
{RPCResult::Type::OBJ, "", "utxo being spent, omitted if block undo data is not available", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for missing this earlier, but I think the ", omitted ..." part will need to be removed as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@MarcoFalke see #26968
Added
ScriptPubKeyDoc
function