Files
purple-electrumwallet/scripts/get_history
T

18 lines
329 B
Python
Raw Normal View History

2012-06-14 21:11:37 +02:00
#!/usr/bin/env python
import sys
2013-10-06 12:28:45 +02:00
from electrum import Network
2012-06-14 21:11:37 +02:00
try:
addr = sys.argv[1]
except:
print "usage: get_history <bitcoin_address>"
sys.exit(1)
2013-10-06 12:28:45 +02:00
n = Network()
n.start(wait=True)
h = n.synchronous_get([ ('blockchain.address.get_history',[addr]) ])[0]
2012-10-19 14:16:02 +02:00
for item in h:
2012-11-06 22:20:54 +01:00
print item['tx_hash'], item['height']
2012-06-14 21:11:37 +02:00