summary import { NetworkInterfaceTapConfiguration , NetworkManagementClient } from "@msinternal/network-resource-manager" ; import { DefaultAzureCredential } from "@azure/identity" ; async function createNetworkInterfaceTapConfigurations ( ) { const subscriptionId = "subid" ; const resourceGroupName = "testrg" ; const networkInterfaceName = "mynic" ; const tapConfigurationName = "tapconfiguration1" ; const tapConfigurationParameters = { virtualNetworkTap : { id : "/subscriptions/subid/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworkTaps/testvtap" } } ; const credential = new DefaultAzureCredential ( ) ; const client = new NetworkManagementClient ( credential , subscriptionId ) ; const result = await client . networkInterfaceTapConfigurations . beginCreateOrUpdateAndWait ( resourceGroupName , networkInterfaceName , tapConfigurationName , tapConfigurationParameters ) ; console . log ( result ) ; } createNetworkInterfaceTapConfigurations ( ) . catch ( console . error ) ;