import requests
import shutil


def download_file(url):
    """ Download file from URL """

    local_filename = url.split("/")[-1]
    with requests.get(url, stream=True) as r:
        with open(f"audios/{local_filename}", "wb") as f:
            shutil.copyfileobj(r.raw, f)

    return local_filename