You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/rpc/blockchain.cpp
+32-1Lines changed: 32 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -943,7 +943,7 @@ static RPCHelpMan getblock()
943
943
"If verbosity is 3, returns an Object with information about block <hash> and information about each transaction, including prevout information for inputs (only for unpruned blocks in the current best chain).\n",
944
944
{
945
945
{"blockhash", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, "The block hash"},
946
-
{"verbosity|verbose", RPCArg::Type::NUM, RPCArg::Default{1}, "0 for hex-encoded data, 1 for a json object, and 2 for json object with transaction data"},
946
+
{"verbosity|verbose", RPCArg::Type::NUM, RPCArg::Default{1}, "0 for hex-encoded data, 1 for a JSON object, 2 for JSON object with transaction data, and 3 for JSON object with transaction data including prevout information for inputs"},
947
947
},
948
948
{
949
949
RPCResult{"for verbosity = 0",
@@ -985,6 +985,37 @@ static RPCHelpMan getblock()
985
985
}},
986
986
}},
987
987
}},
988
+
RPCResult{"for verbosity = 3",
989
+
RPCResult::Type::OBJ, "", "",
990
+
{
991
+
{RPCResult::Type::ELISION, "", "Same output as verbosity = 2"},
992
+
{RPCResult::Type::ARR, "tx", "",
993
+
{
994
+
{RPCResult::Type::OBJ, "", "",
995
+
{
996
+
{RPCResult::Type::ARR, "vin", "",
997
+
{
998
+
{RPCResult::Type::OBJ, "", "",
999
+
{
1000
+
{RPCResult::Type::ELISION, "", "The same output as verbosity = 2"},
1001
+
{RPCResult::Type::OBJ, "prevout", "(Only if undo information is available)",
1002
+
{
1003
+
{RPCResult::Type::BOOL, "generated", "Coinbase or not"},
1004
+
{RPCResult::Type::NUM, "height", "The height of the prevout"},
1005
+
{RPCResult::Type::NUM, "value", "The value in " + CURRENCY_UNIT},
1006
+
{RPCResult::Type::OBJ, "scriptPubKey", "",
1007
+
{
1008
+
{RPCResult::Type::STR, "asm", "The asm"},
1009
+
{RPCResult::Type::STR, "hex", "The hex"},
1010
+
{RPCResult::Type::STR, "address", /* optional */true, "The Bitcoin address (only if a well-defined address exists)"},
1011
+
{RPCResult::Type::STR, "type", "The type, eg 'pubkeyhash'"},
0 commit comments