Bitcoin
Bitcoin
Bitcoin
Das Free-Tier deckt persönliche Projekte ab. Pay-as-you-go skaliert ohne Karte.
gettxoutproof builds a hex-encoded Merkle proof showing that one or more given txids were included in a specific Bitcoin block. The proof is the small set of hashes a verifier needs to reconstruct the block's Merkle root from the listed transactions, which is how a light client confirms a BTC payment was actually mined without downloading the whole block. Pass the array of txids — and, on a node without -txindex, the block hash to look in — to https://bitcoin.therpc.io/YOUR_API_KEY. Hand the result to verifytxoutproof to check it.
verifytxoutproof so the recipient can confirm inclusion in a trust-minimised way.| # | Name | Typ | Erforderlich | Beschreibung |
|---|---|---|---|---|
| 1 | txids | array | Ja | Transaction ids to prove inclusion for. |
| 2 | blockhash | string | Nein | Block to look in (lets the node find txs without -txindex). |
| Typ | Beschreibung |
|---|---|
| string | Hex-encoded Merkle proof; verify it with verifytxoutproof. |
| Code | Meldung | Ursache |
|---|---|---|
-5 | No such mempool or blockchain transaction | The txid is unknown to this node. For arbitrary historical txs the node must run -txindex, or you must pass the blockhash. |
-txindex you must pass the block hash, otherwise the node cannot locate the transaction and returns error -5.