@azure/arm-cognitiveservices 7.3.1 → 7.4.0-alpha.20230220.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 +71 -0
- package/LICENSE +1 -1
- package/dist/index.js +1232 -42
- 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/accountsCreateSample.js +17 -8
- package/dist-esm/samples-dev/accountsCreateSample.js.map +1 -1
- package/dist-esm/samples-dev/accountsDeleteSample.js +12 -4
- package/dist-esm/samples-dev/accountsDeleteSample.js.map +1 -1
- package/dist-esm/samples-dev/accountsGetSample.js +12 -4
- package/dist-esm/samples-dev/accountsGetSample.js.map +1 -1
- package/dist-esm/samples-dev/accountsListByResourceGroupSample.js +12 -4
- package/dist-esm/samples-dev/accountsListByResourceGroupSample.js.map +1 -1
- package/dist-esm/samples-dev/accountsListKeysSample.js +12 -4
- package/dist-esm/samples-dev/accountsListKeysSample.js.map +1 -1
- package/dist-esm/samples-dev/accountsListModelsSample.js +11 -4
- package/dist-esm/samples-dev/accountsListModelsSample.js.map +1 -1
- package/dist-esm/samples-dev/accountsListSample.js +11 -3
- package/dist-esm/samples-dev/accountsListSample.js.map +1 -1
- package/dist-esm/samples-dev/accountsListSkusSample.js +12 -4
- package/dist-esm/samples-dev/accountsListSkusSample.js.map +1 -1
- package/dist-esm/samples-dev/accountsListUsagesSample.js +12 -4
- package/dist-esm/samples-dev/accountsListUsagesSample.js.map +1 -1
- package/dist-esm/samples-dev/accountsRegenerateKeySample.js +12 -4
- package/dist-esm/samples-dev/accountsRegenerateKeySample.js.map +1 -1
- package/dist-esm/samples-dev/accountsUpdateSample.js +12 -4
- package/dist-esm/samples-dev/accountsUpdateSample.js.map +1 -1
- package/dist-esm/samples-dev/checkDomainAvailabilitySample.js +11 -3
- package/dist-esm/samples-dev/checkDomainAvailabilitySample.js.map +1 -1
- package/dist-esm/samples-dev/checkSkuAvailabilitySample.js +11 -3
- package/dist-esm/samples-dev/checkSkuAvailabilitySample.js.map +1 -1
- package/dist-esm/samples-dev/commitmentPlansCreateOrUpdateAssociationSample.d.ts +2 -0
- package/dist-esm/samples-dev/commitmentPlansCreateOrUpdateAssociationSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansCreateOrUpdateAssociationSample.js +43 -0
- package/dist-esm/samples-dev/commitmentPlansCreateOrUpdateAssociationSample.js.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansCreateOrUpdatePlanSample.d.ts +2 -0
- package/dist-esm/samples-dev/commitmentPlansCreateOrUpdatePlanSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansCreateOrUpdatePlanSample.js +50 -0
- package/dist-esm/samples-dev/commitmentPlansCreateOrUpdatePlanSample.js.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansCreateOrUpdateSample.js +11 -4
- package/dist-esm/samples-dev/commitmentPlansCreateOrUpdateSample.js.map +1 -1
- package/dist-esm/samples-dev/commitmentPlansDeleteAssociationSample.d.ts +2 -0
- package/dist-esm/samples-dev/commitmentPlansDeleteAssociationSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansDeleteAssociationSample.js +40 -0
- package/dist-esm/samples-dev/commitmentPlansDeleteAssociationSample.js.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansDeletePlanSample.d.ts +2 -0
- package/dist-esm/samples-dev/commitmentPlansDeletePlanSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansDeletePlanSample.js +39 -0
- package/dist-esm/samples-dev/commitmentPlansDeletePlanSample.js.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansDeleteSample.js +11 -4
- package/dist-esm/samples-dev/commitmentPlansDeleteSample.js.map +1 -1
- package/dist-esm/samples-dev/commitmentPlansGetAssociationSample.d.ts +2 -0
- package/dist-esm/samples-dev/commitmentPlansGetAssociationSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansGetAssociationSample.js +40 -0
- package/dist-esm/samples-dev/commitmentPlansGetAssociationSample.js.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansGetPlanSample.d.ts +2 -0
- package/dist-esm/samples-dev/commitmentPlansGetPlanSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansGetPlanSample.js +39 -0
- package/dist-esm/samples-dev/commitmentPlansGetPlanSample.js.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansGetSample.js +11 -4
- package/dist-esm/samples-dev/commitmentPlansGetSample.js.map +1 -1
- package/dist-esm/samples-dev/commitmentPlansListAssociationsSample.d.ts +2 -0
- package/dist-esm/samples-dev/commitmentPlansListAssociationsSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansListAssociationsSample.js +53 -0
- package/dist-esm/samples-dev/commitmentPlansListAssociationsSample.js.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansListPlansByResourceGroupSample.d.ts +2 -0
- package/dist-esm/samples-dev/commitmentPlansListPlansByResourceGroupSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansListPlansByResourceGroupSample.js +52 -0
- package/dist-esm/samples-dev/commitmentPlansListPlansByResourceGroupSample.js.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansListPlansBySubscriptionSample.d.ts +2 -0
- package/dist-esm/samples-dev/commitmentPlansListPlansBySubscriptionSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansListPlansBySubscriptionSample.js +51 -0
- package/dist-esm/samples-dev/commitmentPlansListPlansBySubscriptionSample.js.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansListSample.js +11 -4
- package/dist-esm/samples-dev/commitmentPlansListSample.js.map +1 -1
- package/dist-esm/samples-dev/commitmentPlansUpdatePlanSample.d.ts +2 -0
- package/dist-esm/samples-dev/commitmentPlansUpdatePlanSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/commitmentPlansUpdatePlanSample.js +40 -0
- package/dist-esm/samples-dev/commitmentPlansUpdatePlanSample.js.map +1 -0
- package/dist-esm/samples-dev/commitmentTiersListSample.js +10 -3
- package/dist-esm/samples-dev/commitmentTiersListSample.js.map +1 -1
- package/dist-esm/samples-dev/deletedAccountsGetSample.js +12 -4
- package/dist-esm/samples-dev/deletedAccountsGetSample.js.map +1 -1
- package/dist-esm/samples-dev/deletedAccountsListSample.js +11 -3
- package/dist-esm/samples-dev/deletedAccountsListSample.js.map +1 -1
- package/dist-esm/samples-dev/deletedAccountsPurgeSample.js +12 -4
- package/dist-esm/samples-dev/deletedAccountsPurgeSample.js.map +1 -1
- package/dist-esm/samples-dev/deploymentsCreateOrUpdateSample.js +11 -4
- package/dist-esm/samples-dev/deploymentsCreateOrUpdateSample.js.map +1 -1
- package/dist-esm/samples-dev/deploymentsDeleteSample.js +11 -4
- package/dist-esm/samples-dev/deploymentsDeleteSample.js.map +1 -1
- package/dist-esm/samples-dev/deploymentsGetSample.js +11 -4
- package/dist-esm/samples-dev/deploymentsGetSample.js.map +1 -1
- package/dist-esm/samples-dev/deploymentsListSample.js +11 -4
- package/dist-esm/samples-dev/deploymentsListSample.js.map +1 -1
- package/dist-esm/samples-dev/operationsListSample.js +11 -3
- package/dist-esm/samples-dev/operationsListSample.js.map +1 -1
- package/dist-esm/samples-dev/privateEndpointConnectionsCreateOrUpdateSample.js +11 -4
- package/dist-esm/samples-dev/privateEndpointConnectionsCreateOrUpdateSample.js.map +1 -1
- package/dist-esm/samples-dev/privateEndpointConnectionsDeleteSample.js +11 -4
- package/dist-esm/samples-dev/privateEndpointConnectionsDeleteSample.js.map +1 -1
- package/dist-esm/samples-dev/privateEndpointConnectionsGetSample.js +11 -4
- package/dist-esm/samples-dev/privateEndpointConnectionsGetSample.js.map +1 -1
- package/dist-esm/samples-dev/privateEndpointConnectionsListSample.js +11 -4
- package/dist-esm/samples-dev/privateEndpointConnectionsListSample.js.map +1 -1
- package/dist-esm/samples-dev/privateLinkResourcesListSample.js +11 -4
- package/dist-esm/samples-dev/privateLinkResourcesListSample.js.map +1 -1
- package/dist-esm/samples-dev/resourceSkusListSample.js +11 -3
- package/dist-esm/samples-dev/resourceSkusListSample.js.map +1 -1
- package/dist-esm/src/cognitiveServicesManagementClient.js +2 -2
- package/dist-esm/src/models/index.d.ts +248 -0
- package/dist-esm/src/models/index.d.ts.map +1 -1
- package/dist-esm/src/models/index.js +36 -0
- package/dist-esm/src/models/index.js.map +1 -1
- package/dist-esm/src/models/mappers.d.ts +10 -0
- package/dist-esm/src/models/mappers.d.ts.map +1 -1
- package/dist-esm/src/models/mappers.js +259 -0
- package/dist-esm/src/models/mappers.js.map +1 -1
- package/dist-esm/src/models/parameters.d.ts +4 -0
- package/dist-esm/src/models/parameters.d.ts.map +1 -1
- package/dist-esm/src/models/parameters.js +36 -2
- package/dist-esm/src/models/parameters.js.map +1 -1
- package/dist-esm/src/operations/accounts.js +0 -3
- package/dist-esm/src/operations/accounts.js.map +1 -1
- package/dist-esm/src/operations/commitmentPlans.d.ts +181 -1
- package/dist-esm/src/operations/commitmentPlans.d.ts.map +1 -1
- package/dist-esm/src/operations/commitmentPlans.js +864 -5
- package/dist-esm/src/operations/commitmentPlans.js.map +1 -1
- package/dist-esm/src/operations/commitmentTiers.js +0 -1
- package/dist-esm/src/operations/commitmentTiers.js.map +1 -1
- package/dist-esm/src/operations/deletedAccounts.js +0 -1
- package/dist-esm/src/operations/deletedAccounts.js.map +1 -1
- package/dist-esm/src/operations/deployments.js +0 -1
- package/dist-esm/src/operations/deployments.js.map +1 -1
- package/dist-esm/src/operations/operations.js +0 -1
- package/dist-esm/src/operations/operations.js.map +1 -1
- package/dist-esm/src/operations/resourceSkus.js +0 -1
- package/dist-esm/src/operations/resourceSkus.js.map +1 -1
- package/dist-esm/src/operationsInterfaces/commitmentPlans.d.ts +132 -1
- package/dist-esm/src/operationsInterfaces/commitmentPlans.d.ts.map +1 -1
- package/dist-esm/src/pagingHelper.d.ts +4 -4
- package/dist-esm/src/pagingHelper.js +4 -4
- package/dist-esm/test/cognitiveservices_examples.d.ts.map +1 -1
- package/dist-esm/test/cognitiveservices_examples.js +19 -0
- package/dist-esm/test/cognitiveservices_examples.js.map +1 -1
- package/package.json +8 -7
- package/review/arm-cognitiveservices.api.md +220 -0
- package/src/cognitiveServicesManagementClient.ts +2 -2
- package/src/models/index.ts +287 -0
- package/src/models/mappers.ts +283 -0
- package/src/models/parameters.ts +42 -2
- package/src/operations/accounts.ts +0 -3
- package/src/operations/commitmentPlans.ts +1222 -47
- package/src/operations/commitmentTiers.ts +0 -1
- package/src/operations/deletedAccounts.ts +0 -1
- package/src/operations/deployments.ts +0 -1
- package/src/operations/operations.ts +0 -1
- package/src/operations/resourceSkus.ts +0 -1
- package/src/operationsInterfaces/commitmentPlans.ts +232 -1
- package/src/pagingHelper.ts +4 -4
- package/types/arm-cognitiveservices.d.ts +423 -4
- package/types/tsdoc-metadata.json +1 -1
|
@@ -10,16 +10,19 @@ import { __asyncValues, __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Returns all the resources of a particular type belonging to a subscription.
|
|
15
17
|
*
|
|
16
18
|
* @summary Returns all the resources of a particular type belonging to a subscription.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/ListDeletedAccountsBySubscription.json
|
|
18
20
|
*/
|
|
19
21
|
function listDeletedAccountsBySubscription() {
|
|
20
22
|
var e_1, _a;
|
|
21
23
|
return __awaiter(this, void 0, void 0, function* () {
|
|
22
|
-
const subscriptionId = "
|
|
24
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] ||
|
|
25
|
+
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx";
|
|
23
26
|
const credential = new DefaultAzureCredential();
|
|
24
27
|
const client = new CognitiveServicesManagementClient(credential, subscriptionId);
|
|
25
28
|
const resArray = new Array();
|
|
@@ -39,5 +42,10 @@ function listDeletedAccountsBySubscription() {
|
|
|
39
42
|
console.log(resArray);
|
|
40
43
|
});
|
|
41
44
|
}
|
|
42
|
-
|
|
45
|
+
function main() {
|
|
46
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
47
|
+
listDeletedAccountsBySubscription();
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
main().catch(console.error);
|
|
43
51
|
//# sourceMappingURL=deletedAccountsListSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deletedAccountsListSample.js","sourceRoot":"","sources":["../../samples-dev/deletedAccountsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"deletedAccountsListSample.js","sourceRoot":"","sources":["../../samples-dev/deletedAccountsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,iCAAiC;;;QAC9C,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC;YAChD,sCAAsC,CAAC;QACzC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,eAAe,CAAC,IAAI,EAAE,CAAA,IAAA;gBAAzC,IAAI,IAAI,WAAA,CAAA;gBACjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,SAAe,IAAI;;QACjB,iCAAiC,EAAE,CAAC;IACtC,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,17 +10,20 @@ import { __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Deletes a Cognitive Services account from the resource group.
|
|
15
17
|
*
|
|
16
18
|
* @summary Deletes a Cognitive Services account from the resource group.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/PurgeDeletedAccount.json
|
|
18
20
|
*/
|
|
19
21
|
function deleteAccount() {
|
|
20
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
const subscriptionId = "
|
|
23
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] ||
|
|
24
|
+
"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx";
|
|
22
25
|
const location = "westus";
|
|
23
|
-
const resourceGroupName = "myResourceGroup";
|
|
26
|
+
const resourceGroupName = process.env["COGNITIVESERVICES_RESOURCE_GROUP"] || "myResourceGroup";
|
|
24
27
|
const accountName = "PropTest01";
|
|
25
28
|
const credential = new DefaultAzureCredential();
|
|
26
29
|
const client = new CognitiveServicesManagementClient(credential, subscriptionId);
|
|
@@ -28,5 +31,10 @@ function deleteAccount() {
|
|
|
28
31
|
console.log(result);
|
|
29
32
|
});
|
|
30
33
|
}
|
|
31
|
-
|
|
34
|
+
function main() {
|
|
35
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
36
|
+
deleteAccount();
|
|
37
|
+
});
|
|
38
|
+
}
|
|
39
|
+
main().catch(console.error);
|
|
32
40
|
//# sourceMappingURL=deletedAccountsPurgeSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deletedAccountsPurgeSample.js","sourceRoot":"","sources":["../../samples-dev/deletedAccountsPurgeSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"deletedAccountsPurgeSample.js","sourceRoot":"","sources":["../../samples-dev/deletedAccountsPurgeSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,aAAa;;QAC1B,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC;YAChD,sCAAsC,CAAC;QACzC,MAAM,QAAQ,GAAG,QAAQ,CAAC;QAC1B,MAAM,iBAAiB,GACrB,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,IAAI,iBAAiB,CAAC;QACvE,MAAM,WAAW,GAAG,YAAY,CAAC;QACjC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,eAAe,CAAC,iBAAiB,CAC3D,QAAQ,EACR,iBAAiB,EACjB,WAAW,CACZ,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,SAAe,IAAI;;QACjB,aAAa,EAAE,CAAC;IAClB,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,16 +10,18 @@ import { __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Update the state of specified deployments associated with the Cognitive Services account.
|
|
15
17
|
*
|
|
16
18
|
* @summary Update the state of specified deployments associated with the Cognitive Services account.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/PutDeployment.json
|
|
18
20
|
*/
|
|
19
21
|
function putDeployment() {
|
|
20
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
const subscriptionId = "subscriptionId";
|
|
22
|
-
const resourceGroupName = "resourceGroupName";
|
|
23
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] || "subscriptionId";
|
|
24
|
+
const resourceGroupName = process.env["COGNITIVESERVICES_RESOURCE_GROUP"] || "resourceGroupName";
|
|
23
25
|
const accountName = "accountName";
|
|
24
26
|
const deploymentName = "deploymentName";
|
|
25
27
|
const deployment = {
|
|
@@ -34,5 +36,10 @@ function putDeployment() {
|
|
|
34
36
|
console.log(result);
|
|
35
37
|
});
|
|
36
38
|
}
|
|
37
|
-
|
|
39
|
+
function main() {
|
|
40
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
41
|
+
putDeployment();
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
main().catch(console.error);
|
|
38
45
|
//# sourceMappingURL=deploymentsCreateOrUpdateSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deploymentsCreateOrUpdateSample.js","sourceRoot":"","sources":["../../samples-dev/deploymentsCreateOrUpdateSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAEL,iCAAiC,EAClC,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"deploymentsCreateOrUpdateSample.js","sourceRoot":"","sources":["../../samples-dev/deploymentsCreateOrUpdateSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAEL,iCAAiC,EAClC,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,aAAa;;QAC1B,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,IAAI,gBAAgB,CAAC;QACvE,MAAM,iBAAiB,GACrB,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,IAAI,mBAAmB,CAAC;QACzE,MAAM,WAAW,GAAG,aAAa,CAAC;QAClC,MAAM,cAAc,GAAG,gBAAgB,CAAC;QACxC,MAAM,UAAU,GAAe;YAC7B,UAAU,EAAE;gBACV,KAAK,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,EAAE;gBACtD,aAAa,EAAE,EAAE,QAAQ,EAAE,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE;aACpD;SACF,CAAC;QACF,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,WAAW,CAAC,0BAA0B,CAChE,iBAAiB,EACjB,WAAW,EACX,cAAc,EACd,UAAU,CACX,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,SAAe,IAAI;;QACjB,aAAa,EAAE,CAAC;IAClB,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,16 +10,18 @@ import { __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Deletes the specified deployment associated with the Cognitive Services account.
|
|
15
17
|
*
|
|
16
18
|
* @summary Deletes the specified deployment associated with the Cognitive Services account.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/DeleteDeployment.json
|
|
18
20
|
*/
|
|
19
21
|
function deleteDeployment() {
|
|
20
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
const subscriptionId = "subscriptionId";
|
|
22
|
-
const resourceGroupName = "resourceGroupName";
|
|
23
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] || "subscriptionId";
|
|
24
|
+
const resourceGroupName = process.env["COGNITIVESERVICES_RESOURCE_GROUP"] || "resourceGroupName";
|
|
23
25
|
const accountName = "accountName";
|
|
24
26
|
const deploymentName = "deploymentName";
|
|
25
27
|
const credential = new DefaultAzureCredential();
|
|
@@ -28,5 +30,10 @@ function deleteDeployment() {
|
|
|
28
30
|
console.log(result);
|
|
29
31
|
});
|
|
30
32
|
}
|
|
31
|
-
|
|
33
|
+
function main() {
|
|
34
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
35
|
+
deleteDeployment();
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
main().catch(console.error);
|
|
32
39
|
//# sourceMappingURL=deploymentsDeleteSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deploymentsDeleteSample.js","sourceRoot":"","sources":["../../samples-dev/deploymentsDeleteSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"deploymentsDeleteSample.js","sourceRoot":"","sources":["../../samples-dev/deploymentsDeleteSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,gBAAgB;;QAC7B,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,IAAI,gBAAgB,CAAC;QACvE,MAAM,iBAAiB,GACrB,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,IAAI,mBAAmB,CAAC;QACzE,MAAM,WAAW,GAAG,aAAa,CAAC;QAClC,MAAM,cAAc,GAAG,gBAAgB,CAAC;QACxC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,WAAW,CAAC,kBAAkB,CACxD,iBAAiB,EACjB,WAAW,EACX,cAAc,CACf,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,SAAe,IAAI;;QACjB,gBAAgB,EAAE,CAAC;IACrB,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,16 +10,18 @@ import { __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Gets the specified deployments associated with the Cognitive Services account.
|
|
15
17
|
*
|
|
16
18
|
* @summary Gets the specified deployments associated with the Cognitive Services account.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/GetDeployment.json
|
|
18
20
|
*/
|
|
19
21
|
function getDeployment() {
|
|
20
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
const subscriptionId = "subscriptionId";
|
|
22
|
-
const resourceGroupName = "resourceGroupName";
|
|
23
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] || "subscriptionId";
|
|
24
|
+
const resourceGroupName = process.env["COGNITIVESERVICES_RESOURCE_GROUP"] || "resourceGroupName";
|
|
23
25
|
const accountName = "accountName";
|
|
24
26
|
const deploymentName = "deploymentName";
|
|
25
27
|
const credential = new DefaultAzureCredential();
|
|
@@ -28,5 +30,10 @@ function getDeployment() {
|
|
|
28
30
|
console.log(result);
|
|
29
31
|
});
|
|
30
32
|
}
|
|
31
|
-
|
|
33
|
+
function main() {
|
|
34
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
35
|
+
getDeployment();
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
main().catch(console.error);
|
|
32
39
|
//# sourceMappingURL=deploymentsGetSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deploymentsGetSample.js","sourceRoot":"","sources":["../../samples-dev/deploymentsGetSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"deploymentsGetSample.js","sourceRoot":"","sources":["../../samples-dev/deploymentsGetSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,aAAa;;QAC1B,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,IAAI,gBAAgB,CAAC;QACvE,MAAM,iBAAiB,GACrB,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,IAAI,mBAAmB,CAAC;QACzE,MAAM,WAAW,GAAG,aAAa,CAAC;QAClC,MAAM,cAAc,GAAG,gBAAgB,CAAC;QACxC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,WAAW,CAAC,GAAG,CACzC,iBAAiB,EACjB,WAAW,EACX,cAAc,CACf,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,SAAe,IAAI;;QACjB,aAAa,EAAE,CAAC;IAClB,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,17 +10,19 @@ import { __asyncValues, __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Gets the deployments associated with the Cognitive Services account.
|
|
15
17
|
*
|
|
16
18
|
* @summary Gets the deployments associated with the Cognitive Services account.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/ListDeployments.json
|
|
18
20
|
*/
|
|
19
21
|
function listDeployments() {
|
|
20
22
|
var e_1, _a;
|
|
21
23
|
return __awaiter(this, void 0, void 0, function* () {
|
|
22
|
-
const subscriptionId = "subscriptionId";
|
|
23
|
-
const resourceGroupName = "resourceGroupName";
|
|
24
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] || "subscriptionId";
|
|
25
|
+
const resourceGroupName = process.env["COGNITIVESERVICES_RESOURCE_GROUP"] || "resourceGroupName";
|
|
24
26
|
const accountName = "accountName";
|
|
25
27
|
const credential = new DefaultAzureCredential();
|
|
26
28
|
const client = new CognitiveServicesManagementClient(credential, subscriptionId);
|
|
@@ -41,5 +43,10 @@ function listDeployments() {
|
|
|
41
43
|
console.log(resArray);
|
|
42
44
|
});
|
|
43
45
|
}
|
|
44
|
-
|
|
46
|
+
function main() {
|
|
47
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
48
|
+
listDeployments();
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
main().catch(console.error);
|
|
45
52
|
//# sourceMappingURL=deploymentsListSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deploymentsListSample.js","sourceRoot":"","sources":["../../samples-dev/deploymentsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"deploymentsListSample.js","sourceRoot":"","sources":["../../samples-dev/deploymentsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,eAAe;;;QAC5B,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,IAAI,gBAAgB,CAAC;QACvE,MAAM,iBAAiB,GACrB,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,IAAI,mBAAmB,CAAC;QACzE,MAAM,WAAW,GAAG,aAAa,CAAC;QAClC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,WAAW,CAAC,IAAI,CAC5C,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,SAAe,IAAI;;QACjB,eAAe,EAAE,CAAC;IACpB,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,16 +10,19 @@ import { __asyncValues, __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Lists all the available Cognitive Services account operations.
|
|
15
17
|
*
|
|
16
18
|
* @summary Lists all the available Cognitive Services account operations.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/GetOperations.json
|
|
18
20
|
*/
|
|
19
21
|
function getOperations() {
|
|
20
22
|
var e_1, _a;
|
|
21
23
|
return __awaiter(this, void 0, void 0, function* () {
|
|
22
|
-
const subscriptionId = "
|
|
24
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] ||
|
|
25
|
+
"00000000-0000-0000-0000-000000000000";
|
|
23
26
|
const credential = new DefaultAzureCredential();
|
|
24
27
|
const client = new CognitiveServicesManagementClient(credential, subscriptionId);
|
|
25
28
|
const resArray = new Array();
|
|
@@ -39,5 +42,10 @@ function getOperations() {
|
|
|
39
42
|
console.log(resArray);
|
|
40
43
|
});
|
|
41
44
|
}
|
|
42
|
-
|
|
45
|
+
function main() {
|
|
46
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
47
|
+
getOperations();
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
main().catch(console.error);
|
|
43
51
|
//# sourceMappingURL=operationsListSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"operationsListSample.js","sourceRoot":"","sources":["../../samples-dev/operationsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"operationsListSample.js","sourceRoot":"","sources":["../../samples-dev/operationsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,aAAa;;;QAC1B,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC;YAChD,sCAAsC,CAAC;QACzC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,UAAU,CAAC,IAAI,EAAE,CAAA,IAAA;gBAApC,IAAI,IAAI,WAAA,CAAA;gBACjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,SAAe,IAAI;;QACjB,aAAa,EAAE,CAAC;IAClB,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,16 +10,18 @@ import { __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Update the state of specified private endpoint connection associated with the Cognitive Services account.
|
|
15
17
|
*
|
|
16
18
|
* @summary Update the state of specified private endpoint connection associated with the Cognitive Services account.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/PutPrivateEndpointConnection.json
|
|
18
20
|
*/
|
|
19
21
|
function putPrivateEndpointConnection() {
|
|
20
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
const subscriptionId = "{subscription-id}";
|
|
22
|
-
const resourceGroupName = "res7687";
|
|
23
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] || "{subscription-id}";
|
|
24
|
+
const resourceGroupName = process.env["COGNITIVESERVICES_RESOURCE_GROUP"] || "res7687";
|
|
23
25
|
const accountName = "sto9699";
|
|
24
26
|
const privateEndpointConnectionName = "{privateEndpointConnectionName}";
|
|
25
27
|
const properties = {
|
|
@@ -36,5 +38,10 @@ function putPrivateEndpointConnection() {
|
|
|
36
38
|
console.log(result);
|
|
37
39
|
});
|
|
38
40
|
}
|
|
39
|
-
|
|
41
|
+
function main() {
|
|
42
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
43
|
+
putPrivateEndpointConnection();
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
main().catch(console.error);
|
|
40
47
|
//# sourceMappingURL=privateEndpointConnectionsCreateOrUpdateSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"privateEndpointConnectionsCreateOrUpdateSample.js","sourceRoot":"","sources":["../../samples-dev/privateEndpointConnectionsCreateOrUpdateSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAEL,iCAAiC,EAClC,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"privateEndpointConnectionsCreateOrUpdateSample.js","sourceRoot":"","sources":["../../samples-dev/privateEndpointConnectionsCreateOrUpdateSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAEL,iCAAiC,EAClC,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,4BAA4B;;QACzC,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,IAAI,mBAAmB,CAAC;QAC1E,MAAM,iBAAiB,GACrB,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,IAAI,SAAS,CAAC;QAC/D,MAAM,WAAW,GAAG,SAAS,CAAC;QAC9B,MAAM,6BAA6B,GAAG,iCAAiC,CAAC;QACxE,MAAM,UAAU,GAA8B;YAC5C,UAAU,EAAE;gBACV,iCAAiC,EAAE;oBACjC,WAAW,EAAE,eAAe;oBAC5B,MAAM,EAAE,UAAU;iBACnB;aACF;SACF,CAAC;QACF,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,0BAA0B,CAAC,0BAA0B,CAC/E,iBAAiB,EACjB,WAAW,EACX,6BAA6B,EAC7B,UAAU,CACX,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,SAAe,IAAI;;QACjB,4BAA4B,EAAE,CAAC;IACjC,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,16 +10,18 @@ import { __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Deletes the specified private endpoint connection associated with the Cognitive Services account.
|
|
15
17
|
*
|
|
16
18
|
* @summary Deletes the specified private endpoint connection associated with the Cognitive Services account.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/DeletePrivateEndpointConnection.json
|
|
18
20
|
*/
|
|
19
21
|
function deletePrivateEndpointConnection() {
|
|
20
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
const subscriptionId = "{subscription-id}";
|
|
22
|
-
const resourceGroupName = "res6977";
|
|
23
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] || "{subscription-id}";
|
|
24
|
+
const resourceGroupName = process.env["COGNITIVESERVICES_RESOURCE_GROUP"] || "res6977";
|
|
23
25
|
const accountName = "sto2527";
|
|
24
26
|
const privateEndpointConnectionName = "{privateEndpointConnectionName}";
|
|
25
27
|
const credential = new DefaultAzureCredential();
|
|
@@ -28,5 +30,10 @@ function deletePrivateEndpointConnection() {
|
|
|
28
30
|
console.log(result);
|
|
29
31
|
});
|
|
30
32
|
}
|
|
31
|
-
|
|
33
|
+
function main() {
|
|
34
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
35
|
+
deletePrivateEndpointConnection();
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
main().catch(console.error);
|
|
32
39
|
//# sourceMappingURL=privateEndpointConnectionsDeleteSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"privateEndpointConnectionsDeleteSample.js","sourceRoot":"","sources":["../../samples-dev/privateEndpointConnectionsDeleteSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"privateEndpointConnectionsDeleteSample.js","sourceRoot":"","sources":["../../samples-dev/privateEndpointConnectionsDeleteSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,+BAA+B;;QAC5C,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,IAAI,mBAAmB,CAAC;QAC1E,MAAM,iBAAiB,GACrB,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,IAAI,SAAS,CAAC;QAC/D,MAAM,WAAW,GAAG,SAAS,CAAC;QAC9B,MAAM,6BAA6B,GAAG,iCAAiC,CAAC;QACxE,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,0BAA0B,CAAC,kBAAkB,CACvE,iBAAiB,EACjB,WAAW,EACX,6BAA6B,CAC9B,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,SAAe,IAAI;;QACjB,+BAA+B,EAAE,CAAC;IACpC,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,16 +10,18 @@ import { __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Gets the specified private endpoint connection associated with the Cognitive Services account.
|
|
15
17
|
*
|
|
16
18
|
* @summary Gets the specified private endpoint connection associated with the Cognitive Services account.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/GetPrivateEndpointConnection.json
|
|
18
20
|
*/
|
|
19
21
|
function getPrivateEndpointConnection() {
|
|
20
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
const subscriptionId = "{subscription-id}";
|
|
22
|
-
const resourceGroupName = "res6977";
|
|
23
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] || "{subscription-id}";
|
|
24
|
+
const resourceGroupName = process.env["COGNITIVESERVICES_RESOURCE_GROUP"] || "res6977";
|
|
23
25
|
const accountName = "sto2527";
|
|
24
26
|
const privateEndpointConnectionName = "{privateEndpointConnectionName}";
|
|
25
27
|
const credential = new DefaultAzureCredential();
|
|
@@ -28,5 +30,10 @@ function getPrivateEndpointConnection() {
|
|
|
28
30
|
console.log(result);
|
|
29
31
|
});
|
|
30
32
|
}
|
|
31
|
-
|
|
33
|
+
function main() {
|
|
34
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
35
|
+
getPrivateEndpointConnection();
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
main().catch(console.error);
|
|
32
39
|
//# sourceMappingURL=privateEndpointConnectionsGetSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"privateEndpointConnectionsGetSample.js","sourceRoot":"","sources":["../../samples-dev/privateEndpointConnectionsGetSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"privateEndpointConnectionsGetSample.js","sourceRoot":"","sources":["../../samples-dev/privateEndpointConnectionsGetSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,4BAA4B;;QACzC,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,IAAI,mBAAmB,CAAC;QAC1E,MAAM,iBAAiB,GACrB,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,IAAI,SAAS,CAAC;QAC/D,MAAM,WAAW,GAAG,SAAS,CAAC;QAC9B,MAAM,6BAA6B,GAAG,iCAAiC,CAAC;QACxE,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,0BAA0B,CAAC,GAAG,CACxD,iBAAiB,EACjB,WAAW,EACX,6BAA6B,CAC9B,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,SAAe,IAAI;;QACjB,4BAA4B,EAAE,CAAC;IACjC,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,16 +10,18 @@ import { __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Gets the private endpoint connections associated with the Cognitive Services account.
|
|
15
17
|
*
|
|
16
18
|
* @summary Gets the private endpoint connections associated with the Cognitive Services account.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/ListPrivateEndpointConnections.json
|
|
18
20
|
*/
|
|
19
21
|
function getPrivateEndpointConnection() {
|
|
20
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
const subscriptionId = "{subscription-id}";
|
|
22
|
-
const resourceGroupName = "res6977";
|
|
23
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] || "{subscription-id}";
|
|
24
|
+
const resourceGroupName = process.env["COGNITIVESERVICES_RESOURCE_GROUP"] || "res6977";
|
|
23
25
|
const accountName = "sto2527";
|
|
24
26
|
const credential = new DefaultAzureCredential();
|
|
25
27
|
const client = new CognitiveServicesManagementClient(credential, subscriptionId);
|
|
@@ -27,5 +29,10 @@ function getPrivateEndpointConnection() {
|
|
|
27
29
|
console.log(result);
|
|
28
30
|
});
|
|
29
31
|
}
|
|
30
|
-
|
|
32
|
+
function main() {
|
|
33
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
34
|
+
getPrivateEndpointConnection();
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
main().catch(console.error);
|
|
31
38
|
//# sourceMappingURL=privateEndpointConnectionsListSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"privateEndpointConnectionsListSample.js","sourceRoot":"","sources":["../../samples-dev/privateEndpointConnectionsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"privateEndpointConnectionsListSample.js","sourceRoot":"","sources":["../../samples-dev/privateEndpointConnectionsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,4BAA4B;;QACzC,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,IAAI,mBAAmB,CAAC;QAC1E,MAAM,iBAAiB,GACrB,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,IAAI,SAAS,CAAC;QAC/D,MAAM,WAAW,GAAG,SAAS,CAAC;QAC9B,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,0BAA0B,CAAC,IAAI,CACzD,iBAAiB,EACjB,WAAW,CACZ,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,SAAe,IAAI;;QACjB,4BAA4B,EAAE,CAAC;IACjC,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,16 +10,18 @@ import { __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Gets the private link resources that need to be created for a Cognitive Services account.
|
|
15
17
|
*
|
|
16
18
|
* @summary Gets the private link resources that need to be created for a Cognitive Services account.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/ListPrivateLinkResources.json
|
|
18
20
|
*/
|
|
19
21
|
function listPrivateLinkResources() {
|
|
20
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
-
const subscriptionId = "{subscription-id}";
|
|
22
|
-
const resourceGroupName = "res6977";
|
|
23
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] || "{subscription-id}";
|
|
24
|
+
const resourceGroupName = process.env["COGNITIVESERVICES_RESOURCE_GROUP"] || "res6977";
|
|
23
25
|
const accountName = "sto2527";
|
|
24
26
|
const credential = new DefaultAzureCredential();
|
|
25
27
|
const client = new CognitiveServicesManagementClient(credential, subscriptionId);
|
|
@@ -27,5 +29,10 @@ function listPrivateLinkResources() {
|
|
|
27
29
|
console.log(result);
|
|
28
30
|
});
|
|
29
31
|
}
|
|
30
|
-
|
|
32
|
+
function main() {
|
|
33
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
34
|
+
listPrivateLinkResources();
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
main().catch(console.error);
|
|
31
38
|
//# sourceMappingURL=privateLinkResourcesListSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"privateLinkResourcesListSample.js","sourceRoot":"","sources":["../../samples-dev/privateLinkResourcesListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"privateLinkResourcesListSample.js","sourceRoot":"","sources":["../../samples-dev/privateLinkResourcesListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,wBAAwB;;QACrC,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,IAAI,mBAAmB,CAAC;QAC1E,MAAM,iBAAiB,GACrB,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,IAAI,SAAS,CAAC;QAC/D,MAAM,WAAW,GAAG,SAAS,CAAC;QAC9B,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,oBAAoB,CAAC,IAAI,CACnD,iBAAiB,EACjB,WAAW,CACZ,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,SAAe,IAAI;;QACjB,wBAAwB,EAAE,CAAC;IAC7B,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -10,16 +10,19 @@ import { __asyncValues, __awaiter } from "tslib";
|
|
|
10
10
|
// Licensed under the MIT License.
|
|
11
11
|
import { CognitiveServicesManagementClient } from "@azure/arm-cognitiveservices";
|
|
12
12
|
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
import * as dotenv from "dotenv";
|
|
14
|
+
dotenv.config();
|
|
13
15
|
/**
|
|
14
16
|
* This sample demonstrates how to Gets the list of Microsoft.CognitiveServices SKUs available for your Subscription.
|
|
15
17
|
*
|
|
16
18
|
* @summary Gets the list of Microsoft.CognitiveServices SKUs available for your Subscription.
|
|
17
|
-
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-
|
|
19
|
+
* x-ms-original-file: specification/cognitiveservices/resource-manager/Microsoft.CognitiveServices/stable/2022-12-01/examples/GetSkus.json
|
|
18
20
|
*/
|
|
19
21
|
function regenerateKeys() {
|
|
20
22
|
var e_1, _a;
|
|
21
23
|
return __awaiter(this, void 0, void 0, function* () {
|
|
22
|
-
const subscriptionId = "
|
|
24
|
+
const subscriptionId = process.env["COGNITIVESERVICES_SUBSCRIPTION_ID"] ||
|
|
25
|
+
"f1c637e4-72ec-4f89-8d2b-0f933c036002";
|
|
23
26
|
const credential = new DefaultAzureCredential();
|
|
24
27
|
const client = new CognitiveServicesManagementClient(credential, subscriptionId);
|
|
25
28
|
const resArray = new Array();
|
|
@@ -39,5 +42,10 @@ function regenerateKeys() {
|
|
|
39
42
|
console.log(resArray);
|
|
40
43
|
});
|
|
41
44
|
}
|
|
42
|
-
|
|
45
|
+
function main() {
|
|
46
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
47
|
+
regenerateKeys();
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
main().catch(console.error);
|
|
43
51
|
//# sourceMappingURL=resourceSkusListSample.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resourceSkusListSample.js","sourceRoot":"","sources":["../../samples-dev/resourceSkusListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"resourceSkusListSample.js","sourceRoot":"","sources":["../../samples-dev/resourceSkusListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AAEjC,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB;;;;;GAKG;AACH,SAAe,cAAc;;;QAC3B,MAAM,cAAc,GAClB,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC;YAChD,sCAAsC,CAAC;QACzC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,YAAY,CAAC,IAAI,EAAE,CAAA,IAAA;gBAAtC,IAAI,IAAI,WAAA,CAAA;gBACjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,SAAe,IAAI;;QACjB,cAAc,EAAE,CAAC;IACnB,CAAC;CAAA;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -34,7 +34,7 @@ export class CognitiveServicesManagementClient extends coreClient.ServiceClient
|
|
|
34
34
|
requestContentType: "application/json; charset=utf-8",
|
|
35
35
|
credential: credentials
|
|
36
36
|
};
|
|
37
|
-
const packageDetails = `azsdk-js-arm-cognitiveservices/7.
|
|
37
|
+
const packageDetails = `azsdk-js-arm-cognitiveservices/7.4.0`;
|
|
38
38
|
const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
|
|
39
39
|
? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
|
|
40
40
|
: `${packageDetails}`;
|
|
@@ -67,7 +67,7 @@ export class CognitiveServicesManagementClient extends coreClient.ServiceClient
|
|
|
67
67
|
this.subscriptionId = subscriptionId;
|
|
68
68
|
// Assigning values to Constant parameters
|
|
69
69
|
this.$host = options.$host || "https://management.azure.com";
|
|
70
|
-
this.apiVersion = options.apiVersion || "2022-
|
|
70
|
+
this.apiVersion = options.apiVersion || "2022-12-01";
|
|
71
71
|
this.accounts = new AccountsImpl(this);
|
|
72
72
|
this.deletedAccounts = new DeletedAccountsImpl(this);
|
|
73
73
|
this.resourceSkus = new ResourceSkusImpl(this);
|