Change from urllib2 to requests framework (urllib3). Move version string to config. Add custom headers to http requests.