summary import { NetworkManagementClient } from "@msinternal/network-resource-manager" ; import { DefaultAzureCredential } from "@azure/identity" ; async function virtualHubRouteTableV2Delete ( ) { const subscriptionId = "subid" ; const resourceGroupName = "rg1" ; const virtualHubName = "hub1" ; const connectionName = "conn1" ; const credential = new DefaultAzureCredential ( ) ; const client = new NetworkManagementClient ( credential , subscriptionId ) ; const result = await client . virtualHubBgpConnection . beginDeleteAndWait ( resourceGroupName , virtualHubName , connectionName ) ; console . log ( result ) ; } virtualHubRouteTableV2Delete ( ) . catch ( console . error ) ;