Post
Topic
Board Development & Technical Discussion
Topic OP
Bitcoin Mining Technical Details. Help
by
xDilettante
on 10/10/2023, 19:49:59 UTC
Hey, everybody. I'm trying to figure out how Bitcoin works. I'm getting a little bit of it, but I'm not getting some of it. I ask for help from knowledgeable and understanding Bitcoin coders.

I can get HASH transactions by double hashing (sha256) HEX data (raw transaction). But I can't find information and examples how to get TXID transaction.

For example:

Code:
{
    "result": {
        "in_active_chain": true,
        "txid": "f0acda99bd6f1042f98e042853e99dc0febb55325dda6ce8c4df7fe307816631",
        "hash": "eb55e1c0fc83dda66b9d69701ee6f79a49b5af73952600766d6d3af83fb9046e",
        "version": 1,
        "size": 262,
        "vsize": 235,
        "weight": 940,
        "locktime": 3758567493,
        "vin": [
            {
                "coinbase": "03e7610c0446f724652f4d41524120506f6f6c2ffabe6d6d621175c7c1371ebd43cefcefc3ab0453b7f952101cb5575976420d0104e9f0dd01000000000000006ffead5c76d2571ade6aa17dc7be6bde12b33031f30094000000ffffffff",
                "txinwitness": [
                    "0000000000000000000000000000000000000000000000000000000000000000"
                ],
                "sequence": 4294967295
            }
        ],
        "vout": [
            {
                "value": 6.3601069,
                "n": 0,
                "scriptPubKey": {
                    "asm": "OP_DUP OP_HASH160 2fc701e2049ee4957b07134b6c1d771dd5a96b21 OP_EQUALVERIFY OP_CHECKSIG",
                    "desc": "addr(15MdAHnkxt9TMC2Rj595hsg8Hnv693pPBB)#j6z3mx70",
                    "hex": "76a9142fc701e2049ee4957b07134b6c1d771dd5a96b2188ac",
                    "address": "15MdAHnkxt9TMC2Rj595hsg8Hnv693pPBB",
                    "type": "pubkeyhash"
                }
            },
            {
                "value": 0.0,
                "n": 1,
                "scriptPubKey": {
                    "asm": "OP_RETURN aa21a9edaf182da3eb02887057bacf92ae319a024020f02c8d50537fe33f45f1c922e08d",
                    "desc": "raw(6a24aa21a9edaf182da3eb02887057bacf92ae319a024020f02c8d50537fe33f45f1c922e08d)#rst44kmt",
                    "hex": "6a24aa21a9edaf182da3eb02887057bacf92ae319a024020f02c8d50537fe33f45f1c922e08d",
                    "type": "nulldata"
                }
            }
        ],
        "hex": "010000000001010000000000000000000000000000000000000000000000000000000000000000ffffffff5e03e7610c0446f724652f4d41524120506f6f6c2ffabe6d6d621175c7c1371ebd43cefcefc3ab0453b7f952101cb5575976420d0104e9f0dd01000000000000006ffead5c76d2571ade6aa17dc7be6bde12b33031f30094000000ffffffffffffffff02c2c0e825000000001976a9142fc701e2049ee4957b07134b6c1d771dd5a96b2188ac0000000000000000266a24aa21a9edaf182da3eb02887057bacf92ae319a024020f02c8d50537fe33f45f1c922e08d01200000000000000000000000000000000000000000000000000000000000000000453007e0",
        "blockhash": "00000000000000000000bd684e36789d16da2cf5b08b47deb72d1448a73eae5c",
        "confirmations": 77,
        "time": 1696921412,
        "blocktime": 1696921412
    },
    "error": null,
    "id": "1"
}

What data from this block do I need to hash to get TXID?