def download_url(self, timeout=60, name=None):
        if "local" in self.driver.name.lower():
            return url_for(SERVER_ENDPOINT,
                           object_name=self.name,
                           dl=1,
                           name=name,
                           _external=True)
        else:
            driver_name = self.driver.name.lower()
            expires = (datetime.datetime.now()
                       + datetime.timedelta(seconds=timeout)).strftime("%s")

            if 's3' in driver_name or 'google' in driver_name:

                s2s = "GET\n\n\n{expires}\n/{object_name}"\
                    .format(expires=expires, object_name=self.path)
                h = hmac.new(self.driver.secret, s2s, hashlib.sha1)
                s = base64.encodestring(h.digest()).strip()
                _keyIdName = "AWSAccessKeyId" if "s3" in driver_name else "GoogleAccessId"
                params = {
                    _keyIdName: self.driver.key,
                    "Expires": expires,
                    "Signature": s
                }
                urlkv = urlencode(params)
                return "%s?%s" % (self.secure_url, urlkv)

            elif 'cloudfiles' in driver_name:
                return self.driver.ex_get_object_temp_url(self._obj,
                                                               method="GET",
                                                               timeout=expires)
            else:
                raise NotImplemented("This provider '%s' doesn't support or "
                                     "doesn't have a signed url "
                                     "implemented yet" % self.provider_name)
Trigger a browse download
dataset/ETHPy150Open mardix/flask-cloudy/flask_cloudy.py/Object.download_url