Thanks alot!!!
You're welcome.
You might wanna check dive into python and the python standard library for python 2 and python 3.
Also, maybe lock this thread if all is okay and don't hesitate to shoot me a pm if you need anything.
Good luck .
It was the Bitcointalk forum that inspired us to create Bitcointalksearch.org - Bitcointalk is an excellent site that should be the default page for anybody dealing in cryptocurrency, since it is a virtual gold-mine of data. However, our experience and user feedback led us create our site; Bitcointalk's search is slow, and difficult to get the results you need, because you need to log in first to find anything useful - furthermore, there are rate limiters for their search functionality.
The aim of our project is to create a faster website that yields more results and faster without having to create an account and eliminate the need to log in - your personal data, therefore, will never be in jeopardy since we are not asking for any of your data and you don't need to provide them to use our site with all of its capabilities.
We created this website with the sole purpose of users being able to search quickly and efficiently in the field of cryptocurrency so they will have access to the latest and most accurate information and thereby assisting the crypto-community at large.
Name: John Smith
Address: 1234567890...
....
for line in addresses:
if line.startswith("Address: "): # Test that the line is an address line
address = line.strip("Address: ") # Remove the prefix Address:
urlRequest = urllib2.Request("http://localhost:3001/insight-api/addr/" + address)
data = urllib2.urlopen(urlRequest).read()
json_data = json.loads(data)
balances.write("Balance of " + address + " is " + str(json_data["balance"]) + "\n")
....
balances.write("Balance of " + address.strip("\n") + " is " + str(json_data["balance"]) + "\n")
#use the right keys
http://localhost:3001/insight-api/addr/+address")
http://localhost:3001/insight-api/addr/+address/balance")
/insight-api/addr/
/insight-api/addr//balance
urllib2.HTTPError: HTTP Error 404: Not Found
url = "http://localhost:3001/insight-api/" + address
print url
import urllib2
import json
addresses = open("addresses.txt", "r")
balances = open("balances.txt", "w")
for address in addresses:
urlRequest = urllib2.Request("http://localhost:3001/insight-api/" + address)
data = urllib2.urlopen(urlRequest).read()
json_data = json.loads(data)
balances.write("Balance of " + address + " is " + str(json_data["data"]["balance"]) + "\n") #use the right keys
addresses.close()
balances.close()
Traceback (most recent call last):
File "self4.py", line 10, in
data = urllib2.urlopen(urlRequest).read()
File "/usr/lib/python2.7/urllib2.py", line 154, in urlopen
return opener.open(url, data, timeout)
File "/usr/lib/python2.7/urllib2.py", line 435, in open
response = meth(req, response)
File "/usr/lib/python2.7/urllib2.py", line 548, in http_response
'http', request, response, code, msg, hdrs)
File "/usr/lib/python2.7/urllib2.py", line 473, in error
return self._call_chain(*args)
File "/usr/lib/python2.7/urllib2.py", line 407, in _call_chain
result = func(*args)
File "/usr/lib/python2.7/urllib2.py", line 556, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
urllib2.HTTPError: HTTP Error 404: Not Found
import time
...
...
...
for address in addresses:
urlRequest = urllib2.Request("https://blockchain.info/rawaddr/" + address)
data = urllib2.urlopen(urlRequest).read()
json_data = json.loads(data)
balances.append("Balance of " + address + " is " + str(json_data['final_balance']))
time.sleep(0.5) # 2 connectios per second
...
...
...
first_addr
second_addr
.....
last_addr
f = open("addresses.txt", "r")
for address in f:
....
f = open("balances.txt", "w")
f.write(....)
addresses = open("addresses.txt", "r")
balances = open("balances.txt", "w")
for address in addresses:
urlRequest = urllib2.Request("http://localhost:3001/insight/" + address)
data = urllib2.urlopen(urlRequest).read()
json_data = json.loads(data)
balances.write("Balance of " + address + " is " + str(json_data["data"]["balance"]) + "\n") #use the right keys
addresses.close()
balances.close()
balances = []
for address in addresses:
urlRequest = urllib2.Request("https://blockchain.info/rawaddr/" + address)
data = urllib2.urlopen(urlRequest).read()
json_data = json.loads(data)
balances.append("Balance of " + address + " is " + str(json_data['final_balance']))
"\n".join(balances)
import urllib2
import json
address = raw_input("Enter Address >> ")
urlRequest = urllib2.Request("https://blockchain.info/rawaddr/" + address)
data = urllib2.urlopen(urlRequest).read()
json_data = json.loads(data)
print "Final Balance: " + str(json_data['final_balance'])
import urllib2
import json
address = "your_address"
req = urllib2.Request("http://btc.blockr.io/api/v1/address/info/"+address)
res = urllib2.urlopen(req)
print res.read()
json_data = json.load(res)
print json_data
req = urllib2.Request("http://btc.blockr.io/api/v1/address/info/"+address)
res = urllib2.urlopen(req)
json_data = json.loads(res.read())
def scan(address,pkey):
req = urllib2.Request("http://btc.blockr.io/api/v1/address/info/"+address+"")
res = urllib2.urlopen(req)
json_data = json.load(res)