⚡ We welcome businesses to test our enterprise-grade service

btg
Bitcoin Gold (BTG)

Method: POST gettxoutproof

dropdown

方法 RPC gettxoutproof 例如 Bitcoin Gold (BTG)

POST gettxoutproof

返回十六进制编码的证据,证明“ TXID”已包含在一个街区中。

注意:默认情况下,此功能有时仅能工作。 这是此交易中UTXO中有未输出的时间。 为了使其始终起作用,您需要使用-txindex命令行选项维护交易索引,或指定手动包含交易的块(通过BlockHash)。

Parameters

txids - json阵列,必需

一个txids的json阵列

blockhash - 字符串,可选

如果指定,请使用此哈希在块中查找txid

Request

curl --location --request POST 'https://btg.getblock.io/mainnet/' \
--header 'x-api-key: YOUR-API-KEY' \
--header 'Content-Type: application/json' \
--data-raw '{"jsonrpc": "2.0",
"method": "gettxoutproof",
"params": [["5c970c064d317658a8777ee56f192fe17d5b3afbe242d820b205c2291210f269"], null],
"id": "getblock.io"}'


Response

{
    "error": null,
    "id": "getblock.io",
    "result": "000000203bf834f7a8f5cd2b75c3a224e9bf3924b4f4b4daea753dd8d59055f20000000069f2101229c205b220d842e2fb3a5b7de12f196fe57e77a85876314d060c975c36b80a000000000000000000000000000000000000000000000000000000000083383661c964031d040046f60000000000000000000000000000000000000000000000003a9c0000640c8906341016d6e8e8d1fc1f85493065a530ea0f3bbbbe2aa52326f6d4c06920bcbc35b77657b06ef7073f4e28512ff593480d476bcd5bb44c1e510f0af2a525a002f85515683d9d2dcfee0f669e1b133d0b9610bb3ac1043c45262fc811c75b8170e1c5010000000169f2101229c205b220d842e2fb3a5b7de12f196fe57e77a85876314d060c975c0101"
}