How to Delete files from azure storage using python

| By Webner
  1. First, install azure-storage-blob module.
    pip3 intall azure-storage-blob
  2. Then import ContainerClient:
    from import ContainerClient
  3. After that get your Credentials “Connection string” from the Microsoft official site inside the storage account option.
    azure storage
  4. After that just follow the below-mentioned code:
    from import ContainerClient
    def delete_files_from_azure_storage():
    CONNECT_STR = "Def*******************************************
    CONTAINER_NAME = "Enter container name here"
    container_client = ContainerClient.from_connection_string(conn_str=
    CONNECT_STR, container_name=CONTAINER_NAME)
    for blob in all_files_list:

Leave a Reply

Your email address will not be published. Required fields are marked *