How do I print unspent transaction outputs of an address using pybitcointools
How do I print unspent transaction outputs of an address using pybitcointools I am a beginner looking to write a simple program that takes an input (address) and prints the unspent amount in it. I copied some code from chapter 4 of Mastering Bitcoin to generate a random keypair, and the last lines Andreas had in the code I copied were: > # Generate bitcoin address from public key > print "Bitcoin Address (b58check) is:", bitcoin.pubkey_to_address(public_key) > > # Generate compressed bitcoin address from compressed public key > print "Compressed Bitcoin Address (b58check) is:", \ > bitcoin.pubkey_to_address(hex_compressed_public_key) I added the following bit at the end that prints the UTXO. It is currently printing "[ ]" because there are no UTXOs because I'm generating a new address, but it at least works when I do this and prints something. > #Print the UTXO for the given address ...