summary import { PrivateDnsZoneGroup , NetworkManagementClient } from "@msinternal/network-resource-manager" ; import { DefaultAzureCredential } from "@azure/identity" ; async function createPrivateDnsZoneGroup ( ) { const subscriptionId = "subId" ; const resourceGroupName = "rg1" ; const privateEndpointName = "testPe" ; const privateDnsZoneGroupName = "testPdnsgroup" ; const parameters = { privateDnsZoneConfigs : [ { privateDnsZoneId : "/subscriptions/subId/resourceGroups/rg1/providers/Microsoft.Network/privateDnsZones/zone1.com" } ] } ; const credential = new DefaultAzureCredential ( ) ; const client = new NetworkManagementClient ( credential , subscriptionId ) ; const result = await client . privateDnsZoneGroups . beginCreateOrUpdateAndWait ( resourceGroupName , privateEndpointName , privateDnsZoneGroupName , parameters ) ; console . log ( result ) ; } createPrivateDnsZoneGroup ( ) . catch ( console . error ) ;