Skip to content

getdsproofscore JSON-RPC command

getdsproofscore "txid"

Return a double-spend confidence score for a mempool transaction.

Arguments

1. txid (string, required) The in-memory txid to query.

Result

``` n (numeric) A value from 0.0 to 1.0, with 1.0 indicating that the transaction in question has no current dsproofs for it or any of its mempool ancestors, but that a future dsproof is possible. Confidence that this transaction has no known double-spends is relatively high.

       A value of 0.0 indicates that the tx in question or one of its
       mempool ancestors has a dsproof, or that it or one of its mempool
       ancestors does not support dsproofs (not P2PKH), so confidence in
       this tx should be low.

```

       A value of 0.25 indicates that either

- This tx or one of its ancestors did not have all inputs signed with SIGHASH_ALL or one of said inputs was signed with SIGHASH_ANYONECANPAY (which indicates very weak dsproof protection), or; - Up to the first 20,000 ancestors were checked and all have no proofs but *can* have proofs. Since the tx in question has a very large mempool ancestor set, double-spend confidence should be considered medium-to-low. (This value may also be returned for transactions which exceed depth 1,000 in an unconfirmed ancestor chain).

Examples

```

bitcoin-cli getdsproofscore d3aac244e46f4bc5e2140a07496a179624b42d12600bfeafc358154ec89a720c curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "getdsproofscore", "params": [d3aac244e46f4bc5e2140a07496a179624b42d12600bfeafc358154ec89a720c] }' -H 'content-type: text/plain;' http://127.0.0.1:8332/ ```


Bitcoin Cash Node Daemon version v29.0.1-71febb2

Documentation on docs.bitcoincashnode.org reflects the current master branch in Git, and may include API changes that are not yet present in the latest release.