@azure/arm-datadog 3.0.1-alpha.20220411.1 → 3.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +3 -7
- package/README.md +11 -0
- package/dist/index.js +129 -66
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/dist-esm/samples-dev/marketplaceAgreementsCreateOrUpdateSample.d.ts +2 -0
- package/dist-esm/samples-dev/marketplaceAgreementsCreateOrUpdateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/marketplaceAgreementsCreateOrUpdateSample.js +29 -0
- package/dist-esm/samples-dev/marketplaceAgreementsCreateOrUpdateSample.js.map +1 -0
- package/dist-esm/samples-dev/marketplaceAgreementsListSample.d.ts +2 -0
- package/dist-esm/samples-dev/marketplaceAgreementsListSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/marketplaceAgreementsListSample.js +43 -0
- package/dist-esm/samples-dev/marketplaceAgreementsListSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsCreateSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsCreateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsCreateSample.js +31 -0
- package/dist-esm/samples-dev/monitorsCreateSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsDeleteSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsDeleteSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsDeleteSample.js +31 -0
- package/dist-esm/samples-dev/monitorsDeleteSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsGetDefaultKeySample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsGetDefaultKeySample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsGetDefaultKeySample.js +31 -0
- package/dist-esm/samples-dev/monitorsGetDefaultKeySample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsGetSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsGetSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsGetSample.js +31 -0
- package/dist-esm/samples-dev/monitorsGetSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsListApiKeysSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsListApiKeysSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsListApiKeysSample.js +45 -0
- package/dist-esm/samples-dev/monitorsListApiKeysSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsListByResourceGroupSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsListByResourceGroupSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsListByResourceGroupSample.js +44 -0
- package/dist-esm/samples-dev/monitorsListByResourceGroupSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsListHostsSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsListHostsSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsListHostsSample.js +45 -0
- package/dist-esm/samples-dev/monitorsListHostsSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsListLinkedResourcesSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsListLinkedResourcesSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsListLinkedResourcesSample.js +45 -0
- package/dist-esm/samples-dev/monitorsListLinkedResourcesSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsListMonitoredResourcesSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsListMonitoredResourcesSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsListMonitoredResourcesSample.js +45 -0
- package/dist-esm/samples-dev/monitorsListMonitoredResourcesSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsListSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsListSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsListSample.js +43 -0
- package/dist-esm/samples-dev/monitorsListSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsRefreshSetPasswordLinkSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsRefreshSetPasswordLinkSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsRefreshSetPasswordLinkSample.js +31 -0
- package/dist-esm/samples-dev/monitorsRefreshSetPasswordLinkSample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsSetDefaultKeySample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsSetDefaultKeySample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsSetDefaultKeySample.js +31 -0
- package/dist-esm/samples-dev/monitorsSetDefaultKeySample.js.map +1 -0
- package/dist-esm/samples-dev/monitorsUpdateSample.d.ts +2 -0
- package/dist-esm/samples-dev/monitorsUpdateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/monitorsUpdateSample.js +31 -0
- package/dist-esm/samples-dev/monitorsUpdateSample.js.map +1 -0
- package/dist-esm/samples-dev/operationsListSample.d.ts +2 -0
- package/dist-esm/samples-dev/operationsListSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/operationsListSample.js +43 -0
- package/dist-esm/samples-dev/operationsListSample.js.map +1 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsCreateOrUpdateSample.d.ts +2 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsCreateOrUpdateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsCreateOrUpdateSample.js +32 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsCreateOrUpdateSample.js.map +1 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsGetSample.d.ts +2 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsGetSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsGetSample.js +32 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsGetSample.js.map +1 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsListSample.d.ts +2 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsListSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsListSample.js +45 -0
- package/dist-esm/samples-dev/singleSignOnConfigurationsListSample.js.map +1 -0
- package/dist-esm/samples-dev/tagRulesCreateOrUpdateSample.d.ts +2 -0
- package/dist-esm/samples-dev/tagRulesCreateOrUpdateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/tagRulesCreateOrUpdateSample.js +32 -0
- package/dist-esm/samples-dev/tagRulesCreateOrUpdateSample.js.map +1 -0
- package/dist-esm/samples-dev/tagRulesGetSample.d.ts +2 -0
- package/dist-esm/samples-dev/tagRulesGetSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/tagRulesGetSample.js +32 -0
- package/dist-esm/samples-dev/tagRulesGetSample.js.map +1 -0
- package/dist-esm/samples-dev/tagRulesListSample.d.ts +2 -0
- package/dist-esm/samples-dev/tagRulesListSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/tagRulesListSample.js +45 -0
- package/dist-esm/samples-dev/tagRulesListSample.js.map +1 -0
- package/dist-esm/src/microsoftDatadogClient.d.ts.map +1 -1
- package/dist-esm/src/microsoftDatadogClient.js +20 -2
- package/dist-esm/src/microsoftDatadogClient.js.map +1 -1
- package/dist-esm/src/operations/monitors.d.ts.map +1 -1
- package/dist-esm/src/operations/monitors.js +9 -3
- package/dist-esm/src/operations/monitors.js.map +1 -1
- package/dist-esm/src/operations/singleSignOnConfigurations.d.ts.map +1 -1
- package/dist-esm/src/operations/singleSignOnConfigurations.js +3 -1
- package/dist-esm/src/operations/singleSignOnConfigurations.js.map +1 -1
- package/package.json +26 -10
- package/rollup.config.js +6 -72
- package/src/microsoftDatadogClient.ts +27 -2
- package/src/operations/monitors.ts +9 -3
- package/src/operations/singleSignOnConfigurations.ts +3 -1
- package/tsconfig.json +19 -5
- package/types/tsdoc-metadata.json +1 -1
- package/LICENSE.txt +0 -21
@@ -0,0 +1,31 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to Create a monitor resource.
|
15
|
+
*
|
16
|
+
* @summary Create a monitor resource.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_Create.json
|
18
|
+
*/
|
19
|
+
function monitorsCreate() {
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
21
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
22
|
+
const resourceGroupName = "myResourceGroup";
|
23
|
+
const monitorName = "myMonitor";
|
24
|
+
const credential = new DefaultAzureCredential();
|
25
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
26
|
+
const result = yield client.monitors.beginCreateAndWait(resourceGroupName, monitorName);
|
27
|
+
console.log(result);
|
28
|
+
});
|
29
|
+
}
|
30
|
+
monitorsCreate().catch(console.error);
|
31
|
+
//# sourceMappingURL=monitorsCreateSample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsCreateSample.js","sourceRoot":"","sources":["../../samples-dev/monitorsCreateSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,cAAc;;QAC3B,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,WAAW,GAAG,WAAW,CAAC;QAChC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,QAAQ,CAAC,kBAAkB,CACrD,iBAAiB,EACjB,WAAW,CACZ,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,cAAc,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsDeleteSample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsDeleteSample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to Delete a monitor resource.
|
15
|
+
*
|
16
|
+
* @summary Delete a monitor resource.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_Delete.json
|
18
|
+
*/
|
19
|
+
function monitorsDelete() {
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
21
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
22
|
+
const resourceGroupName = "myResourceGroup";
|
23
|
+
const monitorName = "myMonitor";
|
24
|
+
const credential = new DefaultAzureCredential();
|
25
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
26
|
+
const result = yield client.monitors.beginDeleteAndWait(resourceGroupName, monitorName);
|
27
|
+
console.log(result);
|
28
|
+
});
|
29
|
+
}
|
30
|
+
monitorsDelete().catch(console.error);
|
31
|
+
//# sourceMappingURL=monitorsDeleteSample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsDeleteSample.js","sourceRoot":"","sources":["../../samples-dev/monitorsDeleteSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,cAAc;;QAC3B,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,WAAW,GAAG,WAAW,CAAC;QAChC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,QAAQ,CAAC,kBAAkB,CACrD,iBAAiB,EACjB,WAAW,CACZ,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,cAAc,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsGetDefaultKeySample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsGetDefaultKeySample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to Get the default api key.
|
15
|
+
*
|
16
|
+
* @summary Get the default api key.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/ApiKeys_GetDefaultKey.json
|
18
|
+
*/
|
19
|
+
function monitorsGetDefaultKey() {
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
21
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
22
|
+
const resourceGroupName = "myResourceGroup";
|
23
|
+
const monitorName = "myMonitor";
|
24
|
+
const credential = new DefaultAzureCredential();
|
25
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
26
|
+
const result = yield client.monitors.getDefaultKey(resourceGroupName, monitorName);
|
27
|
+
console.log(result);
|
28
|
+
});
|
29
|
+
}
|
30
|
+
monitorsGetDefaultKey().catch(console.error);
|
31
|
+
//# sourceMappingURL=monitorsGetDefaultKeySample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsGetDefaultKeySample.js","sourceRoot":"","sources":["../../samples-dev/monitorsGetDefaultKeySample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,qBAAqB;;QAClC,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,WAAW,GAAG,WAAW,CAAC;QAChC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,QAAQ,CAAC,aAAa,CAChD,iBAAiB,EACjB,WAAW,CACZ,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,qBAAqB,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsGetSample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsGetSample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to Get the properties of a specific monitor resource.
|
15
|
+
*
|
16
|
+
* @summary Get the properties of a specific monitor resource.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_Get.json
|
18
|
+
*/
|
19
|
+
function monitorsGet() {
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
21
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
22
|
+
const resourceGroupName = "myResourceGroup";
|
23
|
+
const monitorName = "myMonitor";
|
24
|
+
const credential = new DefaultAzureCredential();
|
25
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
26
|
+
const result = yield client.monitors.get(resourceGroupName, monitorName);
|
27
|
+
console.log(result);
|
28
|
+
});
|
29
|
+
}
|
30
|
+
monitorsGet().catch(console.error);
|
31
|
+
//# sourceMappingURL=monitorsGetSample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsGetSample.js","sourceRoot":"","sources":["../../samples-dev/monitorsGetSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,WAAW;;QACxB,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,WAAW,GAAG,WAAW,CAAC;QAChC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,iBAAiB,EAAE,WAAW,CAAC,CAAC;QACzE,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,WAAW,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListApiKeysSample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsListApiKeysSample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,45 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __asyncValues, __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to List the api keys for a given monitor resource.
|
15
|
+
*
|
16
|
+
* @summary List the api keys for a given monitor resource.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/ApiKeys_List.json
|
18
|
+
*/
|
19
|
+
function monitorsListApiKeys() {
|
20
|
+
var e_1, _a;
|
21
|
+
return __awaiter(this, void 0, void 0, function* () {
|
22
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
23
|
+
const resourceGroupName = "myResourceGroup";
|
24
|
+
const monitorName = "myMonitor";
|
25
|
+
const credential = new DefaultAzureCredential();
|
26
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
27
|
+
const resArray = new Array();
|
28
|
+
try {
|
29
|
+
for (var _b = __asyncValues(client.monitors.listApiKeys(resourceGroupName, monitorName)), _c; _c = yield _b.next(), !_c.done;) {
|
30
|
+
let item = _c.value;
|
31
|
+
resArray.push(item);
|
32
|
+
}
|
33
|
+
}
|
34
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
35
|
+
finally {
|
36
|
+
try {
|
37
|
+
if (_c && !_c.done && (_a = _b.return)) yield _a.call(_b);
|
38
|
+
}
|
39
|
+
finally { if (e_1) throw e_1.error; }
|
40
|
+
}
|
41
|
+
console.log(resArray);
|
42
|
+
});
|
43
|
+
}
|
44
|
+
monitorsListApiKeys().catch(console.error);
|
45
|
+
//# sourceMappingURL=monitorsListApiKeysSample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListApiKeysSample.js","sourceRoot":"","sources":["../../samples-dev/monitorsListApiKeysSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,mBAAmB;;;QAChC,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,WAAW,GAAG,WAAW,CAAC;QAChC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,QAAQ,CAAC,WAAW,CAChD,iBAAiB,EACjB,WAAW,CACZ,CAAA,IAAA;gBAHU,IAAI,IAAI,WAAA,CAAA;gBAIjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,mBAAmB,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListByResourceGroupSample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsListByResourceGroupSample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,44 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __asyncValues, __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to List all monitors under the specified resource group.
|
15
|
+
*
|
16
|
+
* @summary List all monitors under the specified resource group.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_ListByResourceGroup.json
|
18
|
+
*/
|
19
|
+
function monitorsListByResourceGroup() {
|
20
|
+
var e_1, _a;
|
21
|
+
return __awaiter(this, void 0, void 0, function* () {
|
22
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
23
|
+
const resourceGroupName = "myResourceGroup";
|
24
|
+
const credential = new DefaultAzureCredential();
|
25
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
26
|
+
const resArray = new Array();
|
27
|
+
try {
|
28
|
+
for (var _b = __asyncValues(client.monitors.listByResourceGroup(resourceGroupName)), _c; _c = yield _b.next(), !_c.done;) {
|
29
|
+
let item = _c.value;
|
30
|
+
resArray.push(item);
|
31
|
+
}
|
32
|
+
}
|
33
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
34
|
+
finally {
|
35
|
+
try {
|
36
|
+
if (_c && !_c.done && (_a = _b.return)) yield _a.call(_b);
|
37
|
+
}
|
38
|
+
finally { if (e_1) throw e_1.error; }
|
39
|
+
}
|
40
|
+
console.log(resArray);
|
41
|
+
});
|
42
|
+
}
|
43
|
+
monitorsListByResourceGroup().catch(console.error);
|
44
|
+
//# sourceMappingURL=monitorsListByResourceGroupSample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListByResourceGroupSample.js","sourceRoot":"","sources":["../../samples-dev/monitorsListByResourceGroupSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,2BAA2B;;;QACxC,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,QAAQ,CAAC,mBAAmB,CACxD,iBAAiB,CAClB,CAAA,IAAA;gBAFU,IAAI,IAAI,WAAA,CAAA;gBAGjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,2BAA2B,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListHostsSample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsListHostsSample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,45 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __asyncValues, __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to List the hosts for a given monitor resource.
|
15
|
+
*
|
16
|
+
* @summary List the hosts for a given monitor resource.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Hosts_List.json
|
18
|
+
*/
|
19
|
+
function monitorsListHosts() {
|
20
|
+
var e_1, _a;
|
21
|
+
return __awaiter(this, void 0, void 0, function* () {
|
22
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
23
|
+
const resourceGroupName = "myResourceGroup";
|
24
|
+
const monitorName = "myMonitor";
|
25
|
+
const credential = new DefaultAzureCredential();
|
26
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
27
|
+
const resArray = new Array();
|
28
|
+
try {
|
29
|
+
for (var _b = __asyncValues(client.monitors.listHosts(resourceGroupName, monitorName)), _c; _c = yield _b.next(), !_c.done;) {
|
30
|
+
let item = _c.value;
|
31
|
+
resArray.push(item);
|
32
|
+
}
|
33
|
+
}
|
34
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
35
|
+
finally {
|
36
|
+
try {
|
37
|
+
if (_c && !_c.done && (_a = _b.return)) yield _a.call(_b);
|
38
|
+
}
|
39
|
+
finally { if (e_1) throw e_1.error; }
|
40
|
+
}
|
41
|
+
console.log(resArray);
|
42
|
+
});
|
43
|
+
}
|
44
|
+
monitorsListHosts().catch(console.error);
|
45
|
+
//# sourceMappingURL=monitorsListHostsSample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListHostsSample.js","sourceRoot":"","sources":["../../samples-dev/monitorsListHostsSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,iBAAiB;;;QAC9B,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,WAAW,GAAG,WAAW,CAAC;QAChC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,QAAQ,CAAC,SAAS,CAC9C,iBAAiB,EACjB,WAAW,CACZ,CAAA,IAAA;gBAHU,IAAI,IAAI,WAAA,CAAA;gBAIjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,iBAAiB,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListLinkedResourcesSample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsListLinkedResourcesSample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,45 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __asyncValues, __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to List all Azure resources associated to the same Datadog organization as the target resource.
|
15
|
+
*
|
16
|
+
* @summary List all Azure resources associated to the same Datadog organization as the target resource.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/LinkedResources_List.json
|
18
|
+
*/
|
19
|
+
function monitorsListLinkedResources() {
|
20
|
+
var e_1, _a;
|
21
|
+
return __awaiter(this, void 0, void 0, function* () {
|
22
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
23
|
+
const resourceGroupName = "myResourceGroup";
|
24
|
+
const monitorName = "myMonitor";
|
25
|
+
const credential = new DefaultAzureCredential();
|
26
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
27
|
+
const resArray = new Array();
|
28
|
+
try {
|
29
|
+
for (var _b = __asyncValues(client.monitors.listLinkedResources(resourceGroupName, monitorName)), _c; _c = yield _b.next(), !_c.done;) {
|
30
|
+
let item = _c.value;
|
31
|
+
resArray.push(item);
|
32
|
+
}
|
33
|
+
}
|
34
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
35
|
+
finally {
|
36
|
+
try {
|
37
|
+
if (_c && !_c.done && (_a = _b.return)) yield _a.call(_b);
|
38
|
+
}
|
39
|
+
finally { if (e_1) throw e_1.error; }
|
40
|
+
}
|
41
|
+
console.log(resArray);
|
42
|
+
});
|
43
|
+
}
|
44
|
+
monitorsListLinkedResources().catch(console.error);
|
45
|
+
//# sourceMappingURL=monitorsListLinkedResourcesSample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListLinkedResourcesSample.js","sourceRoot":"","sources":["../../samples-dev/monitorsListLinkedResourcesSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,2BAA2B;;;QACxC,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,WAAW,GAAG,WAAW,CAAC;QAChC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,QAAQ,CAAC,mBAAmB,CACxD,iBAAiB,EACjB,WAAW,CACZ,CAAA,IAAA;gBAHU,IAAI,IAAI,WAAA,CAAA;gBAIjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,2BAA2B,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListMonitoredResourcesSample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsListMonitoredResourcesSample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,45 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __asyncValues, __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to List the resources currently being monitored by the Datadog monitor resource.
|
15
|
+
*
|
16
|
+
* @summary List the resources currently being monitored by the Datadog monitor resource.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/MonitoredResources_List.json
|
18
|
+
*/
|
19
|
+
function monitorsListMonitoredResources() {
|
20
|
+
var e_1, _a;
|
21
|
+
return __awaiter(this, void 0, void 0, function* () {
|
22
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
23
|
+
const resourceGroupName = "myResourceGroup";
|
24
|
+
const monitorName = "myMonitor";
|
25
|
+
const credential = new DefaultAzureCredential();
|
26
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
27
|
+
const resArray = new Array();
|
28
|
+
try {
|
29
|
+
for (var _b = __asyncValues(client.monitors.listMonitoredResources(resourceGroupName, monitorName)), _c; _c = yield _b.next(), !_c.done;) {
|
30
|
+
let item = _c.value;
|
31
|
+
resArray.push(item);
|
32
|
+
}
|
33
|
+
}
|
34
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
35
|
+
finally {
|
36
|
+
try {
|
37
|
+
if (_c && !_c.done && (_a = _b.return)) yield _a.call(_b);
|
38
|
+
}
|
39
|
+
finally { if (e_1) throw e_1.error; }
|
40
|
+
}
|
41
|
+
console.log(resArray);
|
42
|
+
});
|
43
|
+
}
|
44
|
+
monitorsListMonitoredResources().catch(console.error);
|
45
|
+
//# sourceMappingURL=monitorsListMonitoredResourcesSample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListMonitoredResourcesSample.js","sourceRoot":"","sources":["../../samples-dev/monitorsListMonitoredResourcesSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,8BAA8B;;;QAC3C,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,WAAW,GAAG,WAAW,CAAC;QAChC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,QAAQ,CAAC,sBAAsB,CAC3D,iBAAiB,EACjB,WAAW,CACZ,CAAA,IAAA;gBAHU,IAAI,IAAI,WAAA,CAAA;gBAIjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,8BAA8B,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListSample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsListSample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,43 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __asyncValues, __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to List all monitors under the specified subscription.
|
15
|
+
*
|
16
|
+
* @summary List all monitors under the specified subscription.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_List.json
|
18
|
+
*/
|
19
|
+
function monitorsList() {
|
20
|
+
var e_1, _a;
|
21
|
+
return __awaiter(this, void 0, void 0, function* () {
|
22
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
23
|
+
const credential = new DefaultAzureCredential();
|
24
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
25
|
+
const resArray = new Array();
|
26
|
+
try {
|
27
|
+
for (var _b = __asyncValues(client.monitors.list()), _c; _c = yield _b.next(), !_c.done;) {
|
28
|
+
let item = _c.value;
|
29
|
+
resArray.push(item);
|
30
|
+
}
|
31
|
+
}
|
32
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
33
|
+
finally {
|
34
|
+
try {
|
35
|
+
if (_c && !_c.done && (_a = _b.return)) yield _a.call(_b);
|
36
|
+
}
|
37
|
+
finally { if (e_1) throw e_1.error; }
|
38
|
+
}
|
39
|
+
console.log(resArray);
|
40
|
+
});
|
41
|
+
}
|
42
|
+
monitorsList().catch(console.error);
|
43
|
+
//# sourceMappingURL=monitorsListSample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsListSample.js","sourceRoot":"","sources":["../../samples-dev/monitorsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,YAAY;;;QACzB,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,QAAQ,CAAC,IAAI,EAAE,CAAA,IAAA;gBAAlC,IAAI,IAAI,WAAA,CAAA;gBACjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,YAAY,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsRefreshSetPasswordLinkSample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsRefreshSetPasswordLinkSample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to Refresh the set password link and return a latest one.
|
15
|
+
*
|
16
|
+
* @summary Refresh the set password link and return a latest one.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/RefreshSetPassword_Get.json
|
18
|
+
*/
|
19
|
+
function monitorsRefreshSetPasswordLink() {
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
21
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
22
|
+
const resourceGroupName = "myResourceGroup";
|
23
|
+
const monitorName = "myMonitor";
|
24
|
+
const credential = new DefaultAzureCredential();
|
25
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
26
|
+
const result = yield client.monitors.refreshSetPasswordLink(resourceGroupName, monitorName);
|
27
|
+
console.log(result);
|
28
|
+
});
|
29
|
+
}
|
30
|
+
monitorsRefreshSetPasswordLink().catch(console.error);
|
31
|
+
//# sourceMappingURL=monitorsRefreshSetPasswordLinkSample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsRefreshSetPasswordLinkSample.js","sourceRoot":"","sources":["../../samples-dev/monitorsRefreshSetPasswordLinkSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,8BAA8B;;QAC3C,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,WAAW,GAAG,WAAW,CAAC;QAChC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,QAAQ,CAAC,sBAAsB,CACzD,iBAAiB,EACjB,WAAW,CACZ,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,8BAA8B,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsSetDefaultKeySample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsSetDefaultKeySample.ts"],"names":[],"mappings":""}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
3
|
+
* Licensed under the MIT License.
|
4
|
+
*
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
7
|
+
*/
|
8
|
+
import { __awaiter } from "tslib";
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
10
|
+
// Licensed under the MIT License.
|
11
|
+
import { MicrosoftDatadogClient } from "@azure/arm-datadog";
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
13
|
+
/**
|
14
|
+
* This sample demonstrates how to Set the default api key.
|
15
|
+
*
|
16
|
+
* @summary Set the default api key.
|
17
|
+
* x-ms-original-file: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/ApiKeys_SetDefaultKey.json
|
18
|
+
*/
|
19
|
+
function monitorsSetDefaultKey() {
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
21
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
22
|
+
const resourceGroupName = "myResourceGroup";
|
23
|
+
const monitorName = "myMonitor";
|
24
|
+
const credential = new DefaultAzureCredential();
|
25
|
+
const client = new MicrosoftDatadogClient(credential, subscriptionId);
|
26
|
+
const result = yield client.monitors.setDefaultKey(resourceGroupName, monitorName);
|
27
|
+
console.log(result);
|
28
|
+
});
|
29
|
+
}
|
30
|
+
monitorsSetDefaultKey().catch(console.error);
|
31
|
+
//# sourceMappingURL=monitorsSetDefaultKeySample.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsSetDefaultKeySample.js","sourceRoot":"","sources":["../../samples-dev/monitorsSetDefaultKeySample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,qBAAqB;;QAClC,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,iBAAiB,CAAC;QAC5C,MAAM,WAAW,GAAG,WAAW,CAAC;QAChC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,sBAAsB,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;QACtE,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,QAAQ,CAAC,aAAa,CAChD,iBAAiB,EACjB,WAAW,CACZ,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,qBAAqB,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"monitorsUpdateSample.d.ts","sourceRoot":"","sources":["../../samples-dev/monitorsUpdateSample.ts"],"names":[],"mappings":""}
|