def get_harold(uid, auth_dict=None): data_dict = request.get_json() if data_dict["auth_key"]: auth_models = Auth.query.all() for auth in auth_models: if auth.auth_key == data_dict["auth_key"]: harolds = get_harold_list(uid) return get_file_s3(s3_bucket, random.choice(harolds)) return "Permission denied", 403
def get_s3_url(file_hash, auth_dict=None): # Endpoint to return a presigned url to the s3 asset return redirect(get_file_s3(s3_bucket, file_hash))