summary import { WebSiteManagementClient } from "@msinternal/web-resource-manager" ; import { DefaultAzureCredential } from "@azure/identity" ; async function listDeletedWebAppByLocation ( ) { const subscriptionId = "34adfa4f-cedf-4dc0-ba29-b6d1a69ab345" ; const location = "West US 2" ; const credential = new DefaultAzureCredential ( ) ; const client = new WebSiteManagementClient ( credential , subscriptionId ) ; const resArray = new Array ( ) ; for await ( let item of client . deletedWebApps . listByLocation ( location ) ) { resArray . push ( item ) ; } console . log ( resArray ) ; } listDeletedWebAppByLocation ( ) . catch ( console . error ) ;