def METHOD_NAME(account_name,
                      account_key,
                      container_name,
                      blob_name,
                      permission='w',
                      duration=16):
    """
    Generate a Blob SAS URL to allow a client to upload a file.
    account_name: Storage account name.
    account_key: Storage account key.
    container_name: Storage container.
    blob_name: Blob name.
    duration: A timedelta representing duration until SAS expiration.
       SAS start date will be utcnow() minus one minute. Expiry date
       is start date plus duration.
    Returns the SAS URL.
    """
    sas = SharedAccessSignature(account_name, account_key)
    resource_path = '%s/%s' % (container_name, blob_name)
    date_format = "%Y-%m-%dT%H:%M:%SZ"
    start = datetime.datetime.utcnow() - datetime.timedelta(minutes=5)
    expiry = start + datetime.timedelta(minutes=duration)
    sap = SharedAccessPolicy(AccessPolicy(
            start.strftime(date_format),
            expiry.strftime(date_format),
            permission))
    sas_token = sas.generate_signed_query_string(resource_path, 'b', sap)
    blob_url = BlobService(account_name, account_key)
    url = blob_url.make_blob_url(container_name=container_name, blob_name=blob_name, sas_token=sas_token)
    return url