Hi Suthii09
Welcome to the Microsoft Q&A Platform! Thank you for asking your question here.
Get-AzStorageShare: The cmdlet you should use is part of the Az.Storage module, which is included in the Az module library. It’s the recommended choice for interacting with Azure Storage shares in Azure Automation.
Azure Automation: Azure Automation supports the Az module, and it’s essential to import this module into your Automation account. The Az module is continuously updated with the latest features, which ensures you’re working with the most current and secure resources.
Make sure your Automation account has the right permissions to access the Azure File Share, using a Run As account or Managed Identity.
If your scripts are using AzureRM, we recommend switching to the Az module. Make sure to test your scripts in the Azure Automation environment to ensure they work properly.
https://learn.microsoft.com/en-us/powershell/module/az.storage/?view=azps-13.2.0&viewFallbackFrom=azps-latest
https://learn.microsoft.com/en-us/powershell/azure/new-azureps-module-az?view=azps-13.2.0&viewFallbackFrom=azps-latest
https://learn.microsoft.com/en-us/azure/automation/migrate-run-as-accounts-managed-identity?tabs=sa-managed-identity
https://learn.microsoft.com/en-us/azure/automation/enable-managed-identity-for-automation
If you have any further queries, do let us know.
If the answer is helpful, please and "Upvote it".