You need to be logged in using the Azure Cli (az login
) in order to use DefaultAzureCredential
in C#. Also, you need to make sure to select the subscription that contains the storage account in question (az account set -s SUBSCRIPTION_NAME_OR_ID
).