0

I have 20 addresses generated which are part of a common xpub/ypub. I want to create a combined transaction history of all addresses similar to that of how trezor has the export CSV function. I understand that trezor generates it from the xpub, but in my case I have the addresses but not the xpub.

0
1
  1. Create a watch-only wallet in bitcoin core

  2. Add the addresses using importaddress or importmulti. I imported one address for testing: importaddres tb1qpax3dzmat0qffp3pgkmnmue4tps0xglru65crt "test1" false

  3. Rescan blockchain. I did rescanblockchain 1810000 1896271 for testing

  4. List Transactions for the addresses.

I get the below results:

 
[
  {
    "involvesWatchonly": true,
    "address": "tb1qpax3dzmat0qffp3pgkmnmue4tps0xglru65crt",
    "category": "receive",
    "amount": 0.01200000,
    "label": "test1",
    "vout": 1,
    "confirmations": 57879,
    "blockhash": "000000006ff7a6de9ddedfa8f3dec502e0740b4e19bf9d60091711f442a383fd",
    "blockheight": 1838397,
    "blockindex": 16,
    "blocktime": 1602028580,
    "txid": "98fe1985b800b87a5196c2d1d01980a9930532b0f9b8c5488bfde273cf9b1b01",
    "walletconflicts": [
    ],
    "time": 1602028580,
    "timereceived": 1607228610,
    "bip125-replaceable": "no"
  },
  {
    "involvesWatchonly": true,
    "address": "tb1qj5q83vcsldetj6krhv0jgwexff2vj6xfmd8az6",
    "category": "send",
    "amount": -0.01000000,
    "vout": 1,
    "fee": -0.00000282,
    "confirmations": 4,
    "blockhash": "0000000097539dce940bacac2da89704645862ab878bbb1aa832d5fd3b65c91f",
    "blockheight": 1896272,
    "blockindex": 69,
    "blocktime": 1607229053,
    "txid": "06ff26b56ac6636326cb2f25b6434243a755e2fd2574808271a88ca23fc05b54",
    "walletconflicts": [
    ],
    "time": 1607228776,
    "timereceived": 1607228776,
    "bip125-replaceable": "no",
    "abandoned": false
  },
  {
    "involvesWatchonly": true,
    "address": "tb1qjd4cnkp0zz4dhl2383tugl54dd9eryteya7yjv",
    "category": "send",
    "amount": -0.00199718,
    "vout": 0,
    "fee": -0.00000282,
    "confirmations": 4,
    "blockhash": "0000000097539dce940bacac2da89704645862ab878bbb1aa832d5fd3b65c91f",
    "blockheight": 1896272,
    "blockindex": 69,
    "blocktime": 1607229053,
    "txid": "06ff26b56ac6636326cb2f25b6434243a755e2fd2574808271a88ca23fc05b54",
    "walletconflicts": [
    ],
    "time": 1607228776,
    "timereceived": 1607228776,
    "bip125-replaceable": "no",
    "abandoned": false
  }
]

Results are in JSON format according to my understanding, you can convert them to CSV using one of the available options depending on OS or programming language you prefer to use. Related question: https://unix.stackexchange.com/questions/507615/parse-json-data-using-jq-and-convert-into-csv

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.