Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
Hi @Shobana
Take a look at the Authenticate .NET apps to Azure using developer accounts - .NET | Microsoft Learn guide. Make sure you are signed into the IDE with an account that has necessary RBAC roles to the Azure subscription and that the IDE is configured to use that account for Azure services.
Another issue could be that you're using a work account from one tenant and accessing Azure resources in another tenant. For cases like that, you'll have to set the tenant specifically; for example, credential = new DefaultAzureCredential(new DefaultAzureCredentialOptions { TenantId = "YOUR-TENANT-ID" });. When using managed connection strings, you can apply this value by appending __teantId to the connection name in your app configuration.