UNPKG

@azure/arm-dns

Version:
36 lines 1.56 kB
/* * Copyright (c) Microsoft Corporation. * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ import { __awaiter } from "tslib"; // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. import { DnsManagementClient } from "@azure/arm-dns"; import { DefaultAzureCredential } from "@azure/identity"; /** * This sample demonstrates how to Returns the DNS records specified by the referencing targetResourceIds. * * @summary Returns the DNS records specified by the referencing targetResourceIds. * x-ms-original-file: specification/dns/resource-manager/Microsoft.Network/stable/2018-05-01/examples/GetDnsResourceReference.json */ function listZonesByResourceGroup() { return __awaiter(this, void 0, void 0, function* () { const subscriptionId = "subid"; const parameters = { targetResources: [ { id: "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/trafficManagerProfiles/testpp2" } ] }; const credential = new DefaultAzureCredential(); const client = new DnsManagementClient(credential, subscriptionId); const result = yield client.dnsResourceReferenceOperations.getByTargetResources(parameters); console.log(result); }); } listZonesByResourceGroup().catch(console.error); //# sourceMappingURL=dnsResourceReferenceGetByTargetResourcesSample.js.map