cc-2182: Convert back to restful design
-done
This commit is contained in:
parent
9e01e389ea
commit
8e2019a935
10 changed files with 9 additions and 8 deletions
|
@ -222,11 +222,12 @@ class AirTimeApiClient(ApiClientInterface):
|
|||
try:
|
||||
#src = "http://%s:%s/%s/%s" % \
|
||||
#(self.config["base_url"], str(self.config["base_port"]), self.config["api_base"], self.config["get_media_url"])
|
||||
src = uri
|
||||
src = uri + "/api_key/%%api_key%%"
|
||||
logger.info("try to download from %s to %s", src, dst)
|
||||
src = src.replace("%%api_key%%", self.config["api_key"])
|
||||
# check if file exists already before downloading again
|
||||
filename, headers = urllib.urlretrieve(src, dst)
|
||||
logger.info(headers)
|
||||
except Exception, e:
|
||||
logger.error("%s", e)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue