I'm trying to get a transaction info using
bitcoind gettransaction \
9962d5c704ec27243364cbe9d384808feeac1c15c35ac790dffd1e929829b271
but I'm receiving
error: {"code":-5,"message":"Invalid or non-wallet transaction id"}
How to see a transaction using bitcoin API?
Bitcoin transactions are traceable because Bitcoin's blockchain is completely transparent and every transaction is publicly stored on a distributed ledger.
Cryptocurrency portfolio tracker allows you to track the total amount and value of your cryptocurrencies across all wallets, exchanges, platforms, and blockchains in real-time. These apps let you track historic transactions, their worth, and destinations or sources.
If, after the deadline to report and any extensions have passed, you still have not properly reported your crypto gains on Form 8938, you can face additional fines and penalties. After an initial failure to file, the IRS will notify any taxpayer who hasn't completed their annual return or reports.
While every exchange of cryptocurrency is not currently tracked, it is a matter of time before more regulations impact the anonymity of crypto trading.
You can view foreign transactions using bitcoind.
After you've indexed a few blocks you can use something like this:
$ bitcoind getblockcount
122735
$ bitcoind getblockhash 67543
0000000004e213266ccd388df12896412c1a70e647b48004f7d6894b9d6f63b9
$ bitcoind getblock 0000000004e213266ccd388df12896412c1a70e647b48004f7d6894b9d6f63b9
// JSON containing tx "a93a668d9332e21d51380c7251bbf5ad47295ca9795e0ad6f2fe8d63b76af9aa"
$ bitcoind getrawtransaction a93a668d9332e21d51380c7251bbf5ad47295ca9795e0ad6f2fe8d63b76af9aa 1
// json of transaction - note that "1" at the end tells bitcoind to decode into json
See this for more.
getrawtransaction <txid>
command gets any transaction even from Bitcoin-qt client
Raw Transactions
The "raw transaction API" was introduced with Bitcoin-Qt/bitcoind version 0.7. It gives developers or very sophisticated end-users low-level access to transaction creation and broadcast.
This will return hexadecimal string of bytes, which is not very useful. But if you type
getrawtransaction <txid> 1
you'll get nicely formatted JSON representation
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With